Method and system for operating a self-propelled vehicle according to scene images

ABSTRACT

The present disclosure relates to a robotic system including one or more self-propelled motorized vehicles (SPMV) whose motion is controlled in accordance with electronic image data acquired by one or more observing camera(s) configured to image a scene including the SPMV. In some embodiments, the SPMV includes one or more on-board lights, and the SPMV is operated according to analyzing images acquired by the observing camera before and after an illumination transition of one or more of the point lights. Some embodiments relate techniques to computer gaming and/or to stereoscopic image processing techniques.

CROSS-REFERENCE TO RELATED APPLICATIONS

This patent application is a continuation of U.S. application Ser. No.12/687,126 filed on Jan. 13, 2010, which is incorporated herein byreference in its entirety. U.S. application Ser. No. 12/687,126 claimsthe benefit of U.S. Provisional Patent Application No. 61/204,915, filedJan. 13, 2009 and the benefit of U.S. Provisional Patent Application No.61/241,914, filed Sep. 13, 2009.

FIELD OF THE INVENTION

The present invention relates to robotics and/or computer vision, and insome embodiments, to gaming.

BACKGROUND AND RELATED ART

The following patent documents and non-patent publications describepotentially relevant background art, and are each incorporated herein byreference in their entirety: U.S. Pat. No. 5,471,312, U.S. Pat. No.4,753,569, US 20070243914, US 20070293124, US 20020102910, U.S. Pat. No.6,109,186, U.S. Pat. No. 6,380,844, U.S. Pat. No. 6,780,077, US20090081923, US 20060111014, U.S. Pat. No. 7,402,106, US 20070097832. US20030232649, “Camera Calibration using Mobile Robot in IntelligentSpace” by Takeshi Sasaki′ and Hideki Hashimoto, “Automated Calibrationof a Camera Sensor Network” by Ioannis Rekleitis and Gregory Dudek,“Distributed Smart Camera Calibration using Blinking LED” by MichaelKoch et al.

No admission has been made that any of the aforementioned documents is aprior art document.

SUMMARY OF EMBODIMENTS

It is now disclosed for the first time a gaming system for providing agaming service to a user, the gaming system comprising: a. electroniccontrol circuitry; b. a user-directly-controlled self-propelledmotorized vehicle (SPMV) operative to move responsively towirelessly-received user-generated direct commands provided bymechanical motion and/or brainwaves of the user; c. an array of one ormore cameras configured to generate an electronic image a sceneincluding the user-directly-controlled SPMV; and d. acomputer-directly-controlled SPMV operative to move responsively tocomputer-generated direct commands that generated by the electroniccontrol circuitry in accordance with: i) one or more game objectives;and ii) a position or orientation, within the electronic image of thescene, of the user-directly-controlled SPMV.

In some embodiments, the electronic control circuitry generates commandsto control translational or rotational movement ofcomputer-directly-controlled SPMV in accordance with at least one of: i)a distance between computer-directly-controlled SPMV and/oruser-directly-controlled SPMV and a foreign object as determined inaccordance with a Euclidian scene reconstruction of the electronic sceneimage; ii) historical and/or present and/or predicted future contents ofa Euclidian world description data structure as determined in accordancewith a Euclidian scene reconstruction of the electronic scene image;iii) historical and/or present and/or predicted contents of a game worlddescription data structure.

In some embodiments, the electronic control circuitry includes gamestrategy circuitry for enforcing one or more of the one or more of thegame objectives.

In some embodiments, the electronic control circuitry is operative to:i) detect the user-generated direct commands according to mechanicalmotion of a user control device or according to a detected gesture ofthe or a portion thereof; ii) wirelessly transmit the detected commandsto the user-directly-controlled SPMV.

In some embodiments, the user control device is selected from the groupconsisting of a joystick, a mouse, a keyboard, and an accelerometer.

In some embodiments, the electronic control circuitry is operativegenerate the computer-generated direct commands for controlling thecomputer-directly-controlled SPMV in accordance with game rules ofand/or strategy directives for a game selected from the group consistingof: a) a shooting game; b) a ball game; and c) a hand-to-hand combatgame.

In some embodiments, the control electronic circuitry is operative togenerate the computer-generated direct commands in accordance with ameasured Euclidian distance within the electronic image of the scenebetween the user-directly-controlled SPMV and foreign object in thescene.

In some embodiments, at least one gaming objective is selected from thegroup consisting of: a) an objective to score or a goal with a ball orpuck; b) an objective to block a goal from being scored with a ball orpuck; c) an objective to score or prevent a touchdown or field goal; d)an objective to score a hit against combat game vehicle with aprojectile or abeam of light; e) an objective to reduce a probability ofa hit being scored against a combat game vehicle with a projectile or abeam of light; and f) an objective to move or grab a game prop withcomputer SPMV is the game prop is grabbed by user SPMV.

It is now disclosed for the first time a method of operating aself-propelled motorized vehicle (SPMV) including one or moreelectronically controlled onboard light(s) that effect illuminationtransition(s) that modifies brightness and/or color of one or more ofthe onboard lights, the SPMV located within a scene observed by anobserving electronic camera, the method comprising: a) obtaining firstand second electronic images acquired by the camera, the first imagebeing a pre-transition electronic image IMG_(PRE) describing the beforethe illumination transition and the second electronic image being apost-transition electronic image IMG_(POST) describing the SPMV afterthe illumination transition; and b) comparing the first and secondelectronic images to determine for each onboard light of one or more ofthe onboard lights, a respective pixel location within the first and/orsecond electronic image; c) determining, from the pixel location(s) andcamera calibration data for the camera, a respective Euclidian locationfor each onboard light of the one or more onboard lights; and d) inaccordance with the determined Euclidian location(s) of the on-boardlight(s) electronically controlling rotational and/or translationalmovement of the SPMV or a portion thereof.

It is now disclosed for the first time a method of controlling aself-propelled motorized vehicle (SPMV) including one or more onboardlights operative to effect an illumination transition that modifiesbrightness and/or color of one or more of the onboard lights, the methodcomprising: a) obtaining a time series of images of a scene includingthe SPMV; b) determining a Euclidian location of the SPMV according tothe illumination transition as described by the image time series; andc) controlling rotational and/or translational movement of the SPMV or aportion thereof according to the determined Euclidian location.

It is now disclosed for the first time a method of operating aself-propelled motorized vehicle (SPMV) in accordance with cameracalibration data of an electronic camera, the camera calibration datarelating pixel-image locations to real-world locations, the SPMVincluding one or more onboard lights the method comprising: a)electronically controlling the onboard light(s) of the SPMV to induce anillumination transition that modifies brightness and/or color of one ormore of the onboard lights; b) comparing first and second electronicimages acquired by the camera, the image being a pre-transitionelectronic image IMG_(PRE) describing the SPMV before the illuminationtransition and the second electronic image being a post-transitionelectronic image IMG_(POST) describing the SPMV after the illuminationtransition; and c) in accordance with results of the comparing,electronically controlling rotational and/or translational movement ofthe SPMV or a portion thereof.

In some embodiments, the Euclidian location of the SPMV is determinedprimarily by analyzing one or more image(s) of the image time series.

In some embodiments, the controlling of the rotational and/ortranslational movement of the SPMV is carried out according to thecombination of: i) the Euclidian location of the onboard light(s); andii) other information derivable from one or more electronic imagesacquired by the camera.

In some embodiments, the other information describes one or more foreignobjects in the scene.

In some embodiments, the foreign object information is selected from thegroup consisting of color information for the foreign object, surfacetexture information for the foreign object, and motion informationdescribing translational or rotational motion of the foreign object.

In some embodiments, the controlling of the rotational and/ortranslational movement of the SPMV is carried out according to thecombination of:

-   -   i) the Euclidian location of the onboard light(s); and    -   ii) information that is a Euclidian description of a real or        virtual boundary in the scene.

In some embodiments, the controlling of the rotational and/ortranslational movement of the SPMV is carried out according to thecombination of: i) the Euclidian location of the onboard light(s); andii) a stereoscopic description of the scene obtained by analyzing imagesfrom multiple observing cameras that view the scene.

It is now disclosed for the first time a system comprising: a) aself-propelled motorized vehicle (SPMV) including one or more onboardlights operative to effect an illumination transition that modifiesbrightness and/or color of one or more of the onboard lights b) anobserving camera operative to acquire a time series of images of a sceneincluding the SPMV; and c) electronic circuitry operative to: i)determine a real-world location of the SPMV according to theillumination transition as described by the image time series andaccording to camera calibration data for the observing camera thatrelates pixel-image locations to real-world locations; and ii) controlrotational and/or translational movement of the SPMV or a portionthereof according to the determined real-world location of the SPMV.

It is now disclosed for the first time a system comprising: a) aself-propelled motorized vehicle (SPMV) including one or more onboardlights operative to effect an illumination transition that modifiesbrightness and/or color of one or more of the onboard lights b) anobserving camera operative to acquire a time series of images of a sceneincluding the SPMV; and c) control circuitry operative to controlrotational and/or translational movement of the SPMV or a portionthereof according to a Euclidian location of the SPMV as determined byan illumination transition as described by the image time series.

In some embodiments, the Euclidian location of the SPMV is determinedprimarily by analyzing one or more image(s) of the image time series.

In some embodiments, the controlling of the rotational and/ortranslational movement of the SPMV is carried out according to thecombination of: i) the Euclidian location of the onboard light(s); and

ii) other information derivable from one or more electronic imagesacquired by the camera.

In some embodiments, the other information describes one or more foreignobjects in the scene.

In some embodiments, the foreign object information is selected from thegroup consisting of color information for the foreign object, surfacetexture information for the foreign object, and motion informationdescribing translational or rotational motion of the foreign object.

In some embodiments, the controlling of the rotational and/ortranslational movement of the SPMV is carried out according to thecombination of: i) the Euclidian location of the onboard light(s); andii) information that is a Euclidian description of a real or virtualboundary in the scene.

In some embodiments, the controlling of the rotational and/ortranslational movement of the SPMV is carried out according to thecombination of: i) the Euclidian location of the onboard light(s); andii) a stereoscopic description of the scene obtained by analyzing imagesfrom multiple observing cameras that view the scene.

It is now disclosed for the first time a method of controlling aself-propelled motorized vehicle (SPMV) including one or more onboardlights operative to sequentially effect a plurality of illuminationtransitions, each transition modifying brightness and/or color of one ormore of the onboard lights, the method comprising: a) obtaining a timeseries of images of a scene including the SPMV, each image beinggenerated by an observing camera observing the scene; b) computing,according to a first illumination transition set of one or moreillumination transitions as described by the image time series,calibration data including at least one of: i) camera calibration dataincluding extrinsic camera calibration data for the observing camera,the camera calibration data relating pixel-image locations to Euclidianlocations; ii) SPMV motor calibration data relating SPMV motor energyinputs to Euclidian displacements describing movement of the SPMV or aportion thereof; iii) servo motor calibration data for a servo on whichthe observing camera is mounted, the servo calibration data relatingservo motor energy inputs to perceived Euclidian displacements of theSPMV as perceived by the servo-moved camera moved the servo; c)determining, according to: i) a second illumination transition set ofone or more illumination transitions as described by the image timeseries; and ii) camera and/or SPMV motor and/or servo motor calibrationdata, a Euclidian location of the SPMV; and d) controlling rotationaland/or translational movement of the SPMV or a portion thereof accordingto the determined Euclidian location.

In some embodiments, the Euclidian location determining is carried outprimarily according to images of the image time series.

In some embodiments, i) the calibration data is computed primarilyaccording to analysis of the time series of images; and ii) the analysisincludes analyzing illumination transitions of one or more of theonboard lights.

In some embodiments, i) the obtaining of the images of the image timeseries used for the calibration data computing includes: A) acquiring acalibration set of calibration images that all describe the SPMV in afixed location in (R, Φ) space which describes relative translationaland configurational displacement between camera and SPMV, all images ofthe calibration set of calibration images being identical except forillumination-transition-associated deviations; and B) effecting imagecomparison between images of the calibration set of calibration imagesto compute pixel locations of one or more of the lights at locationsassociated with image transitions of the calibration set and whereimages of the calibration set image deviate from each other; and ii) thecalibration data is determined in accordance with results of the imagesubtractions.

In some embodiments, steps (i)(A) and (i)(B) are carried out a pluralityof times, each time for a different respective fixed location in (R, Φ)space.

In some embodiments, the first and second illumination transition setsare disjoint sets.

In some embodiments, the first and second illumination transition setsare non-disjoint sets.

In some embodiments, the determining of the calibration data includingthe extrinsic calibration data is an ab initio determining for theextrinsic calibration data.

In some embodiments, the controlling is carried out according to acombination of the determine Euclidian location and other sceneinformation present in image(s) of the time series besides informationdescribing the onboard lighting.

It is now disclosed for the first time a method of providing access fora client device or client application to a self-propelled motorizedvehicle (SPMV) that is located in a field of view of an observing camerathe method comprising: a) sending one or more commands to the SPMV or toa servo on which the camera is mounted to induce translational orrotational movement of the SPMV or a portion thereof relative to theobserving camera b) obtaining a time series of images of a sceneincluding the SPMV, each image being generated by the observing cameraand associated with a different location in appearance space (R, Φ, I)for the SPMV that is provided according to the commands of step (a); c)computing, according to differences in the appearance of the SPMV in atleast some of the images of the time series, calibration data includingat least one of: i) camera calibration data including extrinsic cameracalibration data for the observing camera, the camera calibration datarelating pixel-image locations to Euclidian locations; ii) SPMV motorcalibration data relating SPMV motor energy inputs to Euclidiandisplacements describing movement of the SPMV or a portion thereof; iii)servo motor calibration data for a servo on which the observing camerais mounted, the servo calibration data relating servo motor energyinputs to perceived Euclidian displacements of the SPMV as perceived bythe servo-moved camera moved the servo; d) receiving from the clientdevice or the client application a Euclidian command(s) for the SPMV; e)translating the Euclidian movement command(s) to one or more motorcommand(s) according to the calibration data; f) sending the motorcommands of step (e) to the SPMV; g) performing a Euclidian scenereconstruction of one or more images of the time series according to thecalibration data; and h) providing a description of the Euclidian scenereconstruction to the client device or client application. It is nowdisclosed for the first time a method of providing access for a clientdevice or client application to a self-propelled motorized vehicle(SPMV) including one or more onboard lights operative to sequentiallyeffect a plurality of illumination transitions, each transitionmodifying brightness and/or color of one or more of the onboard lights,the method comprising: a) obtaining a time series of images of a sceneincluding the SPMV, each image being generated by an observing cameraobserving the scene; b) computing, according to a illuminationtransition set of one or more illumination transitions as described bythe image time series, calibration data including at least one of: i)camera calibration data including extrinsic camera calibration data forthe observing camera, the camera calibration data relating pixel-imagelocations to Euclidian locations; ii) SPMV motor calibration datarelating SPMV motor energy inputs to Euclidian displacements describingmovement of the SPMV or a portion thereof; iii) servo motor calibrationdata for a servo on which the observing camera is mounted, the servocalibration data relating servo motor energy inputs to perceivedEuclidian displacements of the SPMV as perceived by the servo-movedcamera moved the servo; c) receiving from the client device or theclient application a Euclidian command(s) for the SPMV; d) translatingthe Euclidian movement command(s) to one or more motor command(s)according to the calibration data; e) sending the motor commands of step(d) to the SPMV; f) performing a Euclidian scene reconstruction of oneor more images of the time series according to the calibration data; andg) providing a description of the Euclidian scene reconstruction to theclient device or client application.

It is now disclosed for the first time a method of providing a gamingservice to a user, the gaming system comprising: a. operating auser-directly-controlled self-propelled motorized vehicle (SPMV) to moveresponsively to wirelessly-received user-generated direct commandsprovided by mechanical motion and/or brainwaves of the user; b.obtaining a time series of images of a scene including theuser-directly-controlled SPMV; and c. providing commands to acomputer-generated direct commands in accordance with: i) one or moregame objectives; and ii) a position and/orientation, within theelectronic image(s) of the scene, of the user-directly-controlled SPMV120U.

It is now disclosed for the first time a method of computingpost-rotation extrinsic camera calibration of a camera that is subjectedto a mechanical rotation such that before the motion the camera's fieldof view is FOV_(PRE) and the camera's extrinsic calibration data isdefined by CALIB_(PRE) and after the motion the camera's field ofFOV_(POST), the method comprising: a) before the camera mechanicalrotation, operating the camera to acquire a pre-rotation image IMG_(PRE)associated with FOV_(PRE); b) after the camera mechanical rotation,operating the camera to acquire a post-rotation image IMG_(POST)associated with FOV_(PRE) which has an overlap of between 10% and 70%(for example, between 20% and 40% overlap) with FOV_(PRE); c) if one ofthe pre-rotation image IMG_(PRE) and the post-rotation image IMG_(POST)is designated as a first image and the other of the pre-rotation imageIMG_(PRE) and the post-rotation image IMG_(POST) is designated as thesecond image, for each candidate rotation angle of a plurality ofcandidate rotation angles: i) respectively applying avirtual-camera-rotation transformation function to virtually rotate thefirst image, thereby obtaining a respective angular-transformed image;ii) respectively measuring a pixel-match function describing the pixelmatchings between at least portion of the respective angular-transformedimage and least a portion of the other of the second image; d) accordingto the measured pixel matching functions, selecting a matching candidaterotation angle describing an estimated value of the mechanical rotationvalue of the mechanical rotation to which the camera is subjected; ande) computing the post-rotation camera external calibration data for thecamera according to: i) the preferred candidate rotation angle; and ii)CALIB_(PRE) which defines the camera's extrinsic calibration data beforethe rotation.

In some embodiments, i) the camera is mounted on a servo assembly andwhich subjects the camera to the mechanical rotation according to adelivered power parameter describing delivered power which is deliveredto one or more motors of the servo assembly; ii) the candidate rotationangles are selected according to a relationship between the powerparameter and an estimated rotation provided by the servo assembly.

In some embodiments, the method further comprises: f) controllingtranslational and/or rotational motion of an SPMV in a field of view ofthe camera in accordance with the computed post-rotation camera externalcalibration data.

It is now disclosed a method of operating a self-propelled motorizedvehicle (SPMV) 120 including one or more electronically controlledonboard mechanical shutters 124 that effect mechanical shuttertransition(s) that modifies color appearance of a location on SPMVhousing, the SPMV located within a scene observed by an observingelectronic camera 110, the method comprising: a) obtaining first andsecond electronic images acquired by the camera, the first image being apre-transition electronic image IMG_(PRE) describing the SPMV 120 beforethe mechanical shutter transition and the second electronic image beinga post-transition electronic image IMG_(POST) describing the SPMV 120after the mechanical shutter transition; and b) comparing the first andsecond electronic images to determine for each onboard mechanicalshutter assembly of one or more of the onboard mechanical shutterassemblies, a respective pixel location within the first and/or secondimage c) determining, from the pixel location(s) and camera calibrationdata for the camera, a respective Euclidian location for each onboardmechanical shutter of the one or more onboard mechanical shutter(s); andd) in accordance with the determined Euclidian location(s) of theon-board mechanical shutter(s), electronically controlling rotationaland/or translational movement of the SPMV or a portion thereof.

It is now disclosed for the first time a method of controlling aself-propelled motorized vehicle (SPMV) 120 including one or moreonboard mechanical shutter(s) operative to effect an mechanical shuttertransition that color appearance of a location on SPMV housing, themethod comprising: a) obtaining a time series of images of a sceneincluding the SPMV 120; b) determining a Euclidian location of the SPMVaccording to the mechanical shutter transition as described by the imagetime series; and c) controlling rotational and/or translational movementof the SPMV or a portion thereof according to the determined Euclidianlocation.

It is now disclosed a method of operating a self-propelled motorizedvehicle (SPMV) 120 in accordance with camera calibration data of anelectronic camera 110, the camera calibration data relating pixel-imagelocations to real-world locations, the SPMV including one or moremechanical shutters, the method comprising: a) electronicallycontrolling the onboard mechanical shutter(s) of the SPMV 120 to inducean mechanical shutter transition that modifies a color appearance of alocation on SPMV housing; b) comparing first and second electronicimages acquired by the camera, the image being a pre-transitionelectronic image IMG_(PRE) describing the SPMV 120 before the mechanicalshutter transition and the second electronic image being apost-transition electronic image IMG_(POST) describing the SPMV 120after the mechanical shutter transition; and c) in accordance withresults of the comparing, electronically controlling rotational and/ortranslational movement of the SPMV or a portion thereof.

This summary section should not be construed as limiting the inventionto any features described in this summary section.

BRIEF DESCRIPTION OF THE DRAWINGS

FIGS. 1, 2B illustrate a use case where a human user controls a userrobot in a soccer game against a computer-controlled robot.

FIG. 2A illustrates a self-propelled motorized vehicle (SPMV) includinga plurality of onboard-lights attached to a housing of the SPMV.

FIGS. 3A-3B illustrate a robotic vacuum cleaner.

FIGS. 4A-4D are block diagrams of various systems that include one ormore SMPV(s) in the field of view of one or more camera(s).

FIGS. 5, 6A-6B, 8A-8B are block diagrams of electronic circuitry.

FIG. 7 is a flow chart of a routine for operating a game system.

FIG. 9 is a flow chart of a routine for user direct control of userSPMV.

FIG. 10 is a flow chart of a routine for computer direct control ofcomputer SPMV.

FIGS. 11A and 17 illustrate illumination transitions.

FIG. 11B illustrates pixel locations of a light.

FIG. 12 illustrate camera calibration data.

FIGS. 13, 16A-16B are flow charts for routines of operating an SPMVaccording to illumination transitions.

FIGS. 14A-14E illustrate a use case of FIG. 13.

FIG. 15 is a flow chart of a routine for carrying out step S931.

FIGS. 18A-18B, 19 are routines of operating an SPMV in a self-sufficientsystem.

FIGS. 20A-21C illustrate translations and rotations.

FIG. 22A is an illustration of a servo assembly.

FIG. 22B illustrates a servo motor calibration curve.

FIG. 23 illustrates an SPMV motor calibration curve.

FIGS. 24A-24B are routines of using motor calibration data.

FIGS. 25A-26 relate to mechanical shutter transitions.

FIGS. 27A-27B are a block diagram of a scene reconstruction translationlayer (for example, in software).

FIG. 28A-28B are flow charts of techniques carried out by a scenereconstruction translation layer.

FIG. 29 illustrates two fields of view for a camera depending on thecamera's orientation as provided by the servo assembly.

FIGS. 30A-30B relate to a routine for operating a servo assembly.

DETAILED DESCRIPTION OF EMBODIMENTS Introductory Discussion

Embodiments of the present invention relate to a system and method foroperating a self-propelled motor vehicle (SPMV) according to electronicimages of the SPMV acquired by an ‘observer’ electronic camera viewing ascene which includes the SPMV. Some embodiments of the present inventionrelate to the world of robotic gaming. Other embodiments relate to otherapplications, including but not limited to manufacturing applications,domestic applications, and agricultural applications.

FIG. 1 illustrates a use case related to some gaming embodiments of thepresent invention. In the non-limiting example of FIG. 1, a human user102 plays a robotic soccer game against a computer opponent—the user'srobot 120U (also referred to as a user-directly-controlled SPMV orsimply ‘user SPMV’) defends the user's soccer goal 118U while thecomputer's robot 120C (also referred to as acomputer-directly-controlled SPMV or simply ‘computer SPMV’) defends thecomputer's soccer goal 118C. The scene is viewed by one or moreelectronic camera(s) 110 which repeatedly acquires electronic images ofthe scene including user-directly-controlled SPMV 120U and/orcomputer-directly-controlled SPMV 120C.

Human user 102 employs user input device/controller 104 (exemplarycontrollers include but are not limited to a keyboard or joystick,mobile phone) to generate direct movement commands for user SPMV 120U,and user SPMV moves (i.e. changes its location in R-space or and/or itsconfiguration) in response to the direct movement commands generated byuser input device 104.

In the example of FIG. 1, computer-directly-controlled SPMV 120C isconfigured to play a soccer game against user SPMV 120U in accordancewith (i) contents of the electronic images of the scene acquired byelectronic camera(s) 110 which describe the ‘game world’ and (ii) one ormore game objectives for the game. For the game of soccer (referred toas “football” outside of the United States and Canada), game objectivesmay include attempting to cause ball 114 to cross the plane of user goal118U and attempting to prevent ball 114 from crossing the plane ofcomputer goal 118C.

User SPMV 120U includes an onboard wireless receiver for receiving theuser-generated (i.e. generated by user input device 104 according to theuser's motion or thoughts) commands while computer SPMV 120C includes anonboard wireless receiver for receiving the computer-generated commands.

In one use case, user SPMV 120U controls ball 114 (in sports lingo, SPMV120U is ‘in possession’ of the ball). In this use case, SPMV 120U moveswith ball 114 towards the table on which computer unit 108 is resting.In this use case, to realize one or more of the game objectives listedabove, it may be advantageous for computer-directly-controlled SPMV 120Cto attempt to “steal” the ball 114 from user-directly-controlled SPMV120C. Thus, in this use case, software executing on computer unit 108(i) analyzes images acquired by camera(s) 110 to detect the movement ofuser-directly-controlled SPMV 120C towards the table; and (ii) inresponse to this movement by SPMV 120U, in order to attempt to meet thegame objective, controls SPMV 120C to move towards the table to increasethe likelihood that SPMV 120C could ‘steal’ ball 114 from SPMV 120U.

Although not a requirement, in the non-limiting example of FIG. 1, eachcamera is respectively mounted on a respective mechanical servo assemblyor pan-and-tilt system 112 As will be discussed below, this may beuseful for extending the ‘virtual’ field of view of any camera 110and/or for camera calibration.

The system illustrated in FIG. 1 may be provided using any combinationof software and/or hardware. Some embodiments of FIG. 1 relate to asoftware translation layer having an exposed interface (see for example,FIGS. 27A-27B).

In FIG. 1, the ‘game boundary’ for the soccer game is indicated bynumber 96. In some embodiments, one input influencing how computer SPMV120C operates is a distance between user SPMV 120U and boundary 96, orbetween computer SPMV 120C and boundary 96, or between the ball ‘gameprop’ 114 and boundary 96. In the example of FIG. 1, the game boundaryis a physical boundary visible to the user 102—in another example, theuser may input via computer unit 108 a description of boundary 96.

A more in-depth discussion of FIG. 1 and various game embodiments isprovided below.

Some embodiments of the present invention relate to a technique foroperating an SPMV that includes one or more on-board lights 124 (forexample, LEDs or micro-halogen lights or compact fluorescent lights orany other type of light) (see, for example, FIG. 2A) that are attachedto specific locations on the housing of SPMV 120. These onboard lights124 may be electronically controlled to effect illumination transitionsof brightness or color (a simple example of which is turning on and offof the onboard lights). By comparing an electronic image acquired beforean illumination transition with an electronic image acquired after theillumination transition, it is possible to acquire data (for example,data describing the Euclidian location of the SPMV) useful for operatingthe SPMV. Some embodiments relate to techniques of operating the SPMVhaving onboard lights according to this image comparison data.

Operating the SPMV includes but is not limited to translating, rotatingof the SPMV 120 for any purpose including but not limited to avoiding anobstacle, moving the SPMV 120 in the context of a camera calibrationroutine, to attempt to fulfill one or more game objectives and for amanufacturing purpose.

In some embodiments, this technique for operating the SPMV (described inmore detail below with reference to FIG. 2A and other figures) relatesto robotic gaming—it is noted that onboard lights are not illustrated inFIG. 1, however they may be provided in some embodiments. In anotherexample (see FIG. 3), a robotic vacuum-cleaner (which is also a SPMV120) optionally including onboard lights 124 (see FIG. 3B) attached tothe housing is electronically controlled in response to results of imagecomparison between an image acquired before the illumination transitionand an image acquired after the illumination transition. This may beuseful for a number of purposes, —for example, in order to avoidobstacles, to clean certain locations, etc.

In some embodiments, the system is ‘self-sufficient,’ (i) not requiringany special calibration object and (ii) operative with ‘looselypositioned cameras’ whose position may not be known a-priori (forexample, placed on a substantially flat surface by a user who is notnecessarily a trained technician) (iii) not requiring any additionalrange or position-detecting technologies such as odometers, IR rangefinders, ultrasound sonar etc. It is possible to both (i) electronicallycontrol SPMV 120 (for example, by wirelessly sending commands) to turnonboard lights 124 on and off or to modify color or brightness ofonboard lights 124 and (ii) electronically control translation and/orrotation of SPMV or a component thereof. A series of electronic imagesare acquired for various ‘lighting states’ and various positions and/orconfigurations of SPMV. Calibration data for one or more camera(s) 110may be computed from this series of electronic images.

Furthermore, some embodiments provide routines for calibrating servoassembly 112 and/or a motor of SPMV 120 in a manner that is automatic,does not require any special object, and facilitates a ‘self-sufficient’system within a minimum number of required components.

In the example of FIGS. 1 and 3, a plurality of cameras 110 are employedby the system. Some embodiments of the present invention relate toapparatus and methods for approximate real-time stereoscopic scenereconstruction. In some embodiments, the real-time stereoscopic scenereconstruction may be implemented using only relatively modestcomputational resources.

As noted above, in some embodiment, a servo assembly 112 may be providedto expand the virtual “field of view of camera 110”. Towards this end,some embodiments of the present invention relate to image processingtechniques that may be employed even when relatively low-grade′ servoswithout reliable and/or accurate calibration between electroniccommand(s) to move the servo and the actual angle that the servomechanically rotates in response to the electronic command(s).

In the examples of FIGS. 1 and 3, the camera(s) 110 are in wirelesscommunication with computer 108. In another implementation, camera(s)110 are connected to computer 108 via electrical cable(s).

There is no limitation on the size or shape of SPMV 120 of any otherobject depicted in the figures. Thus, although the SPMV in FIGS. 1, 3Areflect certain ‘length scale’ (for example, appropriate for a toyradio-controlled car or a vacuum cleaner), in other embodiments, SPMV120 may be smaller or much larger (for example, the size of a standardautomobile or even larger).

Throughout the figures, figures that refer specifically to gameembodiments are labeled with the label (“GE”) and figures that refer toboth game embodiments and other game embodiments are labeled with thelabel “GE and Others.”

A Discussion of FIGS. 4A-D

FIG. 4A-4D are block diagrams of various systems that include one ormore SMPV(s) 120 in the field of view of one or more camera(s) 110. Thesystem may be a gaming system, a system for vacuuming a room or cleaninga room (for example, picking up items and putting them away on a shelf),a system used for manufacturing (for example, including a roboticforklift), an office-environment or home-environment system (forexample, including a robotic coffee dispenser), a system used foragriculture (for example, a robotic plow for plowing a field or arobotic fruit or vegetable picker) or any a system provided for anyother purpose.

In the example of FIG. 4A, the system includes a single camera 110 and asingle SPMV 120—the SPMV is located at least in part in the field of thesingle camera. In the example of FIG. 4B, the system includes multiplecameras 110 and a single SPMV 120—the self-propelled vehicle is locatedat least in part in the field of at least one of the cameras. In theexample of FIG. 4B, the system includes multiple cameras 110 and asingle SPMV 120—the self-propelled vehicle is located at least in partin the field of at least one of the cameras. In the example of FIG. 4C,the system includes multiple cameras 110 and multiple self-propelledvehicles 120—each self-propelled vehicle is located at least in part inthe field of at least one of the cameras. In yet another example (seeFIG. 4D), the system includes a single camera 110 and multipleself-propelled vehicles 120.

It is noted that the example of FIG. 1 corresponds to the use-casedescribed in FIG. 4C; the example of FIG. 3 corresponds to the use-caseof FIG. 4B. The SPMV illustrated in FIG. 2 may be used in the context ofany of FIGS. 4A-4D.

The systems of FIGS. 4A-4C also include electronic circuitry 130. Theterm ‘electronic circuitry’ is intended to broadly include anycombination of hardware and software. In the example of FIG. 1, computerunit 108 executing software (for example, image processing software orsoftware for sending control commands to camera 110 and/or SPMV 120) isone example of ‘electronic circuitry’ according to this broaderdefinition.

Electronic circuitry 130 may include may include any executable codemodule (i.e. stored on a computer-readable medium) and/or firmwareand/or hardware element(s) including but not limited to fieldprogrammable logic array (FPLA) element(s), hard-wired logic element(s),field programmable gate array (FPGA) element(s), andapplication-specific integrated circuit (ASIC) element(s). Anyinstruction set architecture may be used including but not limited toreduced instruction set computer (RISC) architecture and/or complexinstruction set computer (CISC) architecture. Electronic circuitry 130may be located in a single location or distributed among a plurality oflocations where various circuitry elements may be in wired or wirelesselectronic communication with each other.

In one non-limiting use case, electronic circuitry 130 includes anexecutable or library running on a standard PC or laptop within astandard operating system environment such as Windows. Some of the lowerlevel control logic of circuitry 130 may be provided as code stored onthe FLASH storage of 8-bit or 32-bit microcontrollers such asMicrochip's PIC18 and PIC32 series.

Locations where the electronic circuitry 130 may reside include but arenot limited to the housing of any self-propelled vehicle 120, in or onthe housing of any camera 110, and in another location (for example,laptop 108 of FIG. 1).

Electronic circuitry 130 may be hardwired and/or configured bycomputer-readable code (for example, as stored in volatile ornon-memory) to effects one or more of the tasks: image processing,controlling the motion of any of the SPMVs 120, controlling one or morecameras 110, controlling a servo motor of a servo assembly 112 uponwhich any camera is mounted (for example, see FIG. 22A)), cameracalibration, servo calibration or any other task.

In the example of FIG. 5, electronic circuitry includes (i) cameraelectronics assembly 80 which is deployed in or on the housing of camera110; (ii) an SPMV electronic assembly 84 which resides in or on SPMV120; and (iii) additional remote electronic assembly 88 (i.e. residingin or on housing of a mechanical element other than the camera 110 andSPMV 120).

In some embodiments, camera electronics assembly 80 may includeelectronic circuitry for providing functionality related to electronicimage acquisition and/or data transfer and/or for any otherfunctionality.

In some embodiments, SPMV electronics assembly 84 may include electroniccircuitry for providing functionality related to moving SPMV 120 totranslate or rotate SPMV or a portion thereof (for example, by operatinga motor, brakes or any other mechanical element) and/or modifying acolor or brightness of one or more onboard lights 124 (for example,turning the light(s) on or off) and/or data transfer and/or for anyother functionality.

In some embodiments, additional electronics assembly 88 may provide anykind of functionality—in one non-limiting example; at least a portion ofadditional electronics assembly 88 resides in laptop computer 108. Inanother non-limiting example, at least a portion of additionalelectronics assembly 88 resides in user input device 104.

As illustrated in FIG. 5, in some embodiments, camera electronicsassembly 80 and/or SPMV electronics assembly 84 and/of additionalelectronics assembly 88 may handle wireless communication.

A Discussion of FIG. 6

FIGS. 6A-6B are block diagrams of electronic circuitry 130 according tosome embodiments. In the example of FIG. 130, electronic circuitryincludes motor vehicle control 140 for controlling translational,rotational or configurational movements of any SPMV 120 (or any portionthereof), camera control 180, servo control 178, image processingcircuitry 160, robotic mechanical appendage control circuitry 142,onboard light control circuitry 182, higher level SPMV control engine196, application objective-implementation circuitry 198, Euclidian worlddescription data structure 144 (for example, residing in volatile and/ornon-volatile computer memory 132), and calibration circuitry 172configured to calibrate camera 110 and/or servo assembly 112 and/or anyonboard motor of any SPMV 120.

Any of the components illustrated in FIGS. 6A-6B (or in any otherfigure—for example, FIGS. 8A-8B) may reside in a single location (anylocation) and/or may be distributed among multiple locations. As withany of the figures, it is appreciated that not every component isrequired in every embodiment. Furthermore, as with any of the figures,it is appreciated that no attempt is made in FIG. 6A (or in any otherfigure) to show all components of electronic circuitry 130.

Camera control 180 may regulate when and/or how often images areacquired by camera(s) 110 (for example, by controlling a mechanical orelectronic shutter or in any other manner), exposure time or any otherparameter related to image acquisition. In one embodiment, cameracontrol 180 does not receive and/or require and/or respond to anyinstructions from outside of camera electronic assembly 80 (for example,from outside of housing of camera 110). For example, camera 110 may bean ordinary video camera which takes periodically takes pictures andwirelessly transmits (or via a data cable) the contents of the picturesfrom camera 110 to computer unit 108 or SPMV 120 or to any otherelectronic device (in this example, there is only outgoing communicationfrom camera 110 to another electronic device without any requiredincoming communication).

Alternatively, it is possible, in some embodiments, to send instructionsto camera control 180 to acquire an electronic image—this may be carriedout wirelessly or in a wired communication (for example, via a cableconnecting camera 110 to computer unit 108).

For embodiments where one or more cameras 110 are mounted on a servoassembly 112, servo control 178 electrically controls the mechanicalmovements of servo assembly 112.

As noted throughout this disclosure, any SPMV 120 may move in accordancewith contents of electronic image(s) acquired by camera(s) 110.Electronic circuitry 130 includes image processing circuitry 160 foranalyzing images. In some embodiments, image processing circuitry 160 isoperative to determine a location or orientation of any SPMV 120 and/orany obstacle and/or any prop (for example, a game prop) and/or any otherobject or visual pattern.

In some embodiments, SPMV 120 includes one or more onboard lights 124(for example, LEDs or Incandescent, car headlights, halogen,mini-halogen, infra-red lights). This may be useful for determining howto operate any SPMV 120 and/or locating any SPMV 120 or portion thereofand/or for camera or servo or motor calibration. Thus, in someembodiments, electronic circuitry 130 includes light control circuitry182 for electronically controlling the on-off state and/or thebrightness and/or color of onboard light(s) 124. As with any illustratedcomponent (for example, camera control 180 discussed above), in someembodiments, it is wirelessly operate to electronically control onboardlight control circuitry 182 (and/or to distribute control onboard lightcontrol circuitry 182 across multiple locations in wirelesscommunication with each other). In another embodiment, onboard lightcontrol 182 is ‘autonomous’ does not receive and/or require and/orrespond to any instructions from outside of control circuitry of SPMVelectronic assembly 84.

Image processing circuitry 160 may be configured to analyze contents ofelectronic image(s) acquired by camera(s) 110 and to determine thelocations of one or more objects and/or to measure the distances betweenobjects. As will be discussed below, in some embodiments, the imageprocessing carried out by image processing circuitry 160 includescomparing images taken before and after a so-called illuminationtransition of one or more on-board lights mounted on any SPMV 120 andcontrolled by onboard light control circuitry 182. The results of theimage comparison may be useful for operating any SPMV 120 (e.g.determining movement commands or any other commands—see the discussionbelow) and/or determining a location or orientation or configuration ofany SPMV 120 or component thereof.

Higher level SPMV control circuitry 196 is operative to determine aplurality of direct commands for any SPMV 120 and/or for issue thesecommands according to some sort of SPMV operation ‘strategy.’ In oneexample related to FIG. 1, higher level SPMV control circuitry 196 iscontrolled by and/or includes and/or is included as part of a gamestrategy engine 170 (discussed below with reference to FIG. 8A). Thus,in one example, in response to a detection that user SPMV 120U isapproaching computer goalpost 118C in ‘possession’ of the ball 114 (i.e.as determined by analyzing electronic image(s) acquired by camera(s)110), higher level SPMV control circuitry 196 may issue a series ofdirect movement commands (including turning commands and commands tomove forward or accelerate) to move computer-controlled SPMV 120Ctowards computer goalpost 118C to attempt to block any movement of ball114 across the plane of computer player goalpost 118C.

In an example related to FIG. 3 and not directly related to gaming,higher level SPMV control circuitry 196 is operative to issue movementcommands to the body of vacuum cleaner 120 and/or to the “vacuum cleanerappendage.” According to this example, a plurality of movement commandsare determined and/or issued by higher level SPMV control circuitry 196in order to attempt to clean the maximum floor area while avoidingand/or moving around various obstacles within the room.

Thus, in some embodiments, higher level SPMV control circuitry 196 mayoperate according to the contents of Euclidian world description datastructure 144 describing the Euclidian location(s) of one or moreobjects within the scene including but not limited to any SPMV 120and/or any obstacle (for example, the table in FIG. 3 or the table orcoach in FIG. 1) and/or any game prop (for example, any goalpost 118 orthe ball 114 in FIG. 1) and/or any other ‘prop’ object (for example, apallet to be lifted by a robotic forklift SPMV 120).

In some embodiments, SPMV 120 may include one or more onboard mechanicalappendages (such as a coffee dispensing assembly or a robotic arm orrobotic hand or robotic forklift) and/or any other onboard accessory(such as an onboard laser—for example, for a cutting or welding robot orfor a ‘laser tag’ game robot). Thus, in some embodiments, electroniccircuitry 130 includes appendage/onboard accessory control circuitry 142(there is no requirement that all circuitry 142 itself be ‘onboard’ onthe SPMV 120 though this is an option—the term ‘onboard’ refers to theappendage or the accessory controlled by the appendage/onboard accessorycontrol circuitry 142).

As will be discussed below, some embodiments, it is useful to effect acalibration of camera 110 and/or servo assembly 112 and/or onboard motor(i.e. for translating, re-orientating or changing a configuration ofSPMV 120 or a portion thereof) of SPMV 120. Thus, in some embodiments,electronic circuitry 130 includes circuitry for calibration of anycamera 110 and/or servo assembly 112 and/or onboard motor of any SPMV120.

Any component or combination of components of FIG. 6A (or of FIG. 8A)may be implemented in any combination of electronics and/or computercode and/or firmware.

FIG. 6B relates to some non-limiting example use cases where variouscomponents are implemented at least in part in computer code/software.Thus, in examples related to FIG. 6B, (i) motor vehicle control 140 isimplemented by the combination of one or more computer processor(s) 138(e.g. microprocessor(s)) and motor vehicle control code 240; (ii) ImageProcessing Circuitry 160 is implemented by the combination of one ormore computer processor(s) 138 (e.g. microprocessor(s)) and ImageProcessing Code 260; (iii) Camera Control Circuitry 180 is implementedby the combination of one or more computer processor(s) 138 (e.g.microprocessor(s)) and Camera Control Code 280; (iv) Servo ControlCircuitry 178 is implemented by the combination of one or more computerprocessor(s) 138 (e.g. microprocessor(s)) and Servo Control Code 278;(v) Control Circuitry 142 for onboard Appendage and/or accessory isimplemented by the combination of one or more computer processor(s) 138(e.g. microprocessor(s)) and Code 242 for controlling onboard Appendageand/or accessory; (vi) Higher level SPMV control Circuitry 196 isimplemented by the combination of one or more computer processor(s) 138(e.g. microprocessor(s)) and Higher level SPMV control Code 296; (vii)onboard light Control Circuitry 182 is implemented by the combination ofone or more computer processor(s) 138 (e.g. microprocessor(s)) andonboard light Control Code 282; (viii) Camera and/or Servo and/or MotorCalibration Circuitry 172 is implemented by the combination of one ormore computer processor(s) 138 (e.g. microprocessor(s)) and Cameraand/or Servo and/or Motor Calibration Code 272

It is appreciated that FIG. 6B is just one particular implementation,and in other embodiments, one or more components (i.e. any number andany combination) or all components are implemented ‘purely in hardware’with no need for computer-executable code.

Computer memory 132 (i.e. shown in FIGS. 6B and 8B) may include volatilememory (examples include but are not limited to random-access memory(RAM) and registers) and non-volatile memory (examples include but arenot limited to read-only memory (ROM) and flash memory).

Although the memory and computer processors are shown as single elementsin FIG. 6B (and in FIG. 8B), it is understood that in differentembodiments, the computer processor 138 which executes a first codeelement (for example, image processing code 160) may be located in adifferent physical location from the computer processor which executes asecond code element (for example, motor vehicle control code 140).

DEFINITIONS

For convenience, in the context of the description herein, various termsare presented here. To the extent that definitions are provided,explicitly or implicitly, here or elsewhere in this application, suchdefinitions are understood to be consistent with the usage of thedefined terms by those of skill in the pertinent art(s). Furthermore,such definitions are to be construed in the broadest possible senseconsistent with such usage.

In a Euclidean representation of the real world, the representationaccurately records the distances, angles, volumes. Parallel lines in thereal world are represented as parallel lines.

In other representations, such as affine or projective, distances may bepreserved but angles not. Parallel lines may not be parallel etc. Theymay nevertheless be able to accurately represent “closer/further than”relations between two points.

Many scene reconstruction techniques cannot create Euclideanrepresentations. These techniques may reconstruct a scene object (e.g.house) as distorted by shears and different sizes in differentdirections.

For the present disclosure, when a quantity or some property is‘determined’ there is no requirement this quantity or property to bedetermined exactly, and it may be determined, for example, onlyapproximately.

For the present disclosure, when a quantity or some property isdetermined or computed or calculated ‘in accordance’ (or ‘according to’)with some sort of parameter, there is no requirement that the quantityor property be determined exclusively in accordance with theparameter—rather, it is meant that the quantity or property isdetermined in accordance with “at least in part.’

A Discussion of Some Gaming Embodiments with Reference to FIGS. 7-10

FIG. 7 is a flow chart of a routine for operating a game systemincluding (i) one or more user SPMV(s) 120U and one or moreopponent/computer controlled SPMVs 120C; (ii) one or more observingcameras 110; (iii) a user control device 104; and (iv) electroniccircuitry 130.

In step S151, the user SPMV 120A receives from user control device 104via a wireless link (for example, a radio link or an IR link or anyother wireless link) one or more direct game commands instructing theremote-control user SPMV 120A to effect one or more game operations.Game operations include but are not limited to commands to accelerate,decelerate, turn, illuminate a light mounted to the SPMV (for example,an LED or a laser light for ‘firing’ at an opponent such as a tank),move to a particular location, and move a robotic arm or leg. The directgame command is generated by user control device 104 in accordance withuser input—for example, in response to a user pressing of a button, auser moving the user control device 104, turning a rotational objectsuch as a knob or wheel, a user generating brainwaves, or any other usermechanical or electrical activity. In another example, user controldevice 104 may be operative to detect human hand gestures (or gesturesof any other human body part) even when the hand is not in contact withuser control device 104.

In step S155, in response to the game command(s) received in step S151,the user remote-controlled SPMV 120I effects one or more of theoperations described by the game commands—for example, by moving one ormore wheels or robotic arms or legs, effecting a steering systemoperation, firing a projectile, or any other operation specified by theuser whose activity is detected by user control device 104.

In step S159, the scene including the remote-control user SPMV 120A isimaged by camera(s) 110. By electronically analyzing the image(s), it ispossible to determine the Euclidian location and/or orientation of anyobject within the scene, based upon camera calibration data. Theseobjects include but are not limited to (i) user-controlled 120U and/orcomputer-controlled/opponent 120C SPMV and/or (ii) one or more gameobjects (for example, a ball) and/or (iii) one or more ‘environmental’objects such as walls or other boundaries, or obstacles (for example, onthe floor).

Typically, step S159 is carried out repeatedly (for example, camera 110may be a video camera)—for example, at least several times a second. Ateach point in time, the physical scene may change, and some sort of‘real world data structure’ maintained in accordance with Euclidianscene reconstruction operations.

In step S163, one or more data storages are updated to reflect theupdated physical ‘real-world’ reality and/or ‘game-world’ realityaccording to the data input received via observing camera(s) 110 andaccording to the Euclidian scene reconstruction. In one example, one ormore SPMV(s) have moved or rotated and their new positions are stored inEuclidian real world description data structure 144 (described belowwith reference to FIG. 6A). In another example, a ball 114 has crossedthe plane of a goal 118 (this may be detected from effecting a Euclidianscene reconstruction of the scene captured by camera(s) 110) and thescore (i.e. describing the ‘game world’ for the soccer game) may beupdated. In this example, game world description data storage 146(described below with reference to FIG. 8A) may be updated.

In step S167, computer SPMV 120C responds, in accordance with (i) one ormore game objective(s); and (ii) the contents of theEuclidian-reconstructed scene which is acquired by observing camera(s)110.

As will be discussed below, in some embodiments of the presentinvention, a ‘game strategy engine’ is provided for facilitating controlof SPMV 120C.

In one example, if user SPMV 120U approaches goalpost 118C, computerSPMV 120C may respond by approaching the goalpost in order to ‘block ashot.’ In this example, the Euclidian scene reconstruction as indicatedby contents of real world description data storage 144 may be read bythe game strategy engine, which may be involved in generating a commandto computer SPMV 120C to move towards the goalpost 118C.

In some embodiments, computer SPMV 120C is configured to operateaccording to the combination of (i) information related to locations andorientations of scene objects that is stored in Euclidian real worlddescription data storage 144; and (ii) additional information—forexample, game data beyond merely the location and/or orientation ofvarious objects (e.g. SPMV(s) or game props or other objects) orboundaries.

Thus, in one example), the amount of time of the soccer game isrecorded, and the player (i.e. either the ‘computer’ player or the‘user’ player) with the higher ‘score’ wins. In this example, if the‘computer’ player is ‘in the lead’ (i.e. had a higher score), the gamestrategy engine or game strategy circuitry (see element 170 of FIG. 8A)may adopt a more ‘conservative’ strategy when operating SPMV 120C, andplace more of an emphasis on blocking goals. If the ‘computer player’ islosing (i.e. the user SPMV 120U has score more goals thus-far), however,SPMV 120C may place a higher emphasis on scoring goals than on blockinggoals.

Information such as the score of the game, the remaining time (i.e. fortimed games), the number of previous fouls per player (for a roboticbasketball game) may be stored in game world description data storage146 (see FIG. 8A), which may augment real world description data storage144 (see FIG. 6A) that describes the Euclidian location/orientation ofscene objects.

The example of FIG. 1 relates to a “computer versus human” soccer game.Various examples may relate to:

-   -   (i) shooting games—in this case, the user may employ radio        controller 104 to instruct user-controlled self-controlled        vehicle 120U fire a projectile or to ‘fire’ using a beam of        light, for example, laser light. In response, opponent or        computer-controlled vehicle 120C may behave according to a game        objective—for example, attempting to dodge one or more        projectiles, attempting to ‘hide’ behind some sort of obstacle        to prevent a line of site between a user vehicle 120U and        computer-controlled vehicle 120C, moving to a position or        orientation where computer-controlled vehicle 120C can shoot        user-controlled vehicle 120U, or firing a shot at user        self-propelled vehicle 120U. In this case, the game events to        which computer-controlled vehicle 120C may relate to a vehicle        being ‘hit’ by a shot, a near miss, movement of a vehicle, etc.        The events may be used for keeping score and/or determining the        behavior of computer-controlled vehicle 120C.    -   (ii) hand-to-hand combat games—for example, a karate match        between a computer SPMV 120C and user SPMV 120U;    -   (iii) maze and/or chasing games—for robotic Pacman where user        SPMV 120U is the “Pacman” and one or more computer SPMVs 120C        are ‘monsters.’;    -   (iv) ball games—for example, computer 120C versus user 120U        robotic baseball or basketball or hockey or American football.

A Discussion of FIGS. 8A-8B

In some embodiments related to gaming, electronic circuitry 130 mayinclude some or all components of FIGS. 6A and/or 6B as well as one ormore additional components illustrated in FIGS. 8A and/or 8B.

Electronic circuitry 130 further may include game logic engine 150 (thisis virtual world information) for enforcing game rules. Game logicengine 150 may maintain update game world description data storage 146according to the set of game rules. One example of a game rule for robotsoccer is that if the ball crosses the plane of the goal a team isawarded one point. In this case, an entry in a data structure of gameworld description repository 144 indicating the score of the game may beupdated game logic engine 150.

One example of a game rule (i.e. that may be enforced by game logiccircuitry) related to robot basketball is if a player (i.e. implementedas a SPMV 120) in possession of the ball goes out-of-bounds, then playis frozen, the clock is stopped, and the other team is to be awardedpossession of the ball. In this case, an entry in a data structuredescribing the amount of time remaining in the game, or who is entitledto receive the ball from a robotic referee, may be updated.

In some embodiments, the game rules enforced by game logic engine 150may relate to informing or alerting a player that a specific game eventhas occurred. Game logic engine 150 may determine whether or not a gameevent (for example, scoring a goal, hitting a tank, etc) has occurred.In one use case, a display screen and/or speaker to present informationto the user may be provided (for example, as part of game controller104), and the user may be alerted via the screen and/or speaker. In oneexample, a player alert engine 152 sends the information, describing thegame event, to the user.

Game strategy circuitry 170 may access game world description datastorage 146 and/or real world description data storage 144 when makingthe strategic decisions for operating computer SPMV 120C according togame objective(s) (see the discussion in the previous section).

Thus, in some embodiments, opponent or computer SPMV 120C may beconfigured to operate according to a game strategy for attempting toachieve one or more game objectives. In one example related to ashooting game (for example, tanks), this game strategy may include (i)moving computer SPMV 120C away from locations where user SPMV 120U canpossibility fire upon opponent/computer controlled SPMV 120B; and/or(ii) re-locating or re-orienting computer SPMV 120C so that it ispossible to successfully fire upon user SPMV 120U.

According to a game strategy, game strategy engine 170 may issue a setof commands for one or more computer SPMV(s) 120C. In one examplerelated to a robotic soccer game, if game strategy engine 170 detectsfrom the contents of game world description repository 144 that thesoccer ball 114 is about to cross the plane of the “computer's” goal (asopposed to the user's/player's goal), game strategy engine 170 mayrespond by issuing a command to the “computer's/opponent's” goalie robot(which is a SPMV 120B) to move to attempt to intercept the soccer ballbefore it crosses the plane of the goal.

In one example, this command may be sent wirelessly toopponent/computer-controlled SPMV 120C via a wireless link. In oneparticular example related to FIG. 1, electronic circuitry of computerunit 108 may be configured by software/computer-executable code as gamestrategy engine 170, and the command(s) issued to computer SPMV 120Caccording to a game strategy and/or by game strategy engine 170 may besent via a wireless link between computer unit 108 and computer SPMV120C.

Any component or combination of components FIG. 8A may be implemented inany combination of electronics and computer code. FIG. 8B relates to thespecific use case where various components are implemented usingcomputer code/software. Thus, FIG. 8B includes user input logic code290, player alert code 252, game strategy engine code 270, game logicengine code 250, and game world description data structure(s) 246 whichreside in memory 132 (see the discussion above with reference to FIG.6B)

A Discussion of FIGS. 9-10

FIG. 9 is a flow chart of a routine whereby the user 102 provides directcommands to user SPMV 120U via input device 104. Direct commands includebut are not limited to direct movement commands, direct commands to arobotic mechanical appendage of an SPMV and direct commands to ‘fire’for shooting games. Direct movement commands include but are not limitedto (i) a command to move (or turn) SPMV to the left; (ii) a command tomove (or turn) SPMV to the right, (iii) a command to stop the SPMV, (iv)a command to move the SPMV forwards, (v) a command to accelerate theSPMV (i.e. press the ‘gas’), (vi) a command to decelerate the SPMV (i.e.press the ‘brake’), (vii) a command to reverse direction (i.e. effect amode transition from ‘forward to backwards’ or from ‘back, forwards);(viii) a command to jump, (ix) a command to climb up (x) a command toclimb down, (xi) a command to turn wheels; (xii) a command to turnwheels to a specific position; (xiii) a command to set motor to aspecific rpm; (xiv) a command to set speed of SPMV to a specific value.

Direct commands to a mechanical robotic appendage (for example, a tankturret or a robotic arm or foot) include: (i) move appendage left; (ii)move appendage right; (iii) kick (for a robotic foot); (iv) accelerate(or decelerate) movement of appendage to the left (or right); (v) grab(for a robotic hand); (vi) rotate clockwise to a specific angle; (vii)rotate anti-clockwise to a specific angle; (viii) rotate at a certainangular velocity; (vi) release (for a robotic hand).

Direct commands to ‘fire’ for shooting games include but are not limitedto (i) a command to fire (either a project, or a ‘light’ such as a laserfor games like laser tag); (ii) a command to accelerate (for decelerate)a rate of repetitive firing; and (iii) a command to cease firing.

In step S511 the user input device 104 detects movements or brainwavesof the user 102 (for example, touching or moving a finger across atouch-screen, pressing a mouse-button, pressing a key on a laptopkeyboard, moving a mouse or the stick of a joystick user 102 hand orbody movements captured by a dedicated user-input camera etc) togenerate a user-descriptive electrical signal describing the useractivity. This signal may be translated/converted, in step S515, into adirect command for operating (for example, for moving) user SPMV 120U.

This electronic conversion of the user-descriptive electrical signalinto direct commands may be carried out, at least in part, in anylocation, including but not limited to electronics assembly of userinput device 104, electronics assembly 88 of laptop 108 (or desktop orany other ‘external’ digital compute that is external to camera(s) 110,the SPMVs 120 and the user input device 104), in electronics assembly 84of any SPMV 120, or in any location.

In some embodiments (not illustrated in FIG. 9), the user-descriptiveelectrical signal and/or one or direct commands for user SPMV 120U maybe wirelessly transmitted—for example, directly from user input device104 to user SPMV 120U or ‘indirectly’ (e.g. via laptop computer 108).

In the specific example of FIG. 1, the user-descriptive electricalsignal describing the user activity is wirelessly transmitted from userinput device 104 to laptop computer 108 (which acts like a central‘brain’ of the user vs. computer game). The conversion or translation ofthe user-descriptive electrical signal into commands for user SPMV 120Uis carried out within the laptop computer 108, and these direct commandsare then transmitted wirelessly to user SPMV 120U.

In some embodiments, it is possible to retain (i.e. in volatile ornon-volatile memory of computer unit 108) information about the directcommands that are routed from user 102 to user SPMV 120U via computerunit 108. For example, this information (i.e. describing direct commanddata) may be entered into to real world description Data structure 144(see FIG. 6A and the accompanying discussion), and utilized, forexample, by Game Strategy Engine 170 (see FIG. 8A and the accompanyingdiscussion). In one example, this information may be particularly usefulwhen user SPMV 120U leaves the field of view of one or more camera(s)110, and it is desired to estimate the location of user SPMV 120U. Inanother example, this information may augment the information providedby one or more electronic images of the scene including user SPMV120U—for example, to reduce the amount of computer resources required toassess a Euclidian location of user SPMV 120U and/or to facilitate amore accurate estimate.

In yet another example, the ‘translation’ of user mechanical engagementsof (or brainwaves) input device 104 into commands for user SPMV 120U maybe carried out within input device 104, and these commands may bewirelessly transmitted by input device 104. In yet another example, userSPMV 120U (for example, circuitry of SPMV electronics assembly 84) may(i) receive the wireless user electronic signal describing usermechanical engagement of input device 104 and (ii) electronicallyconvert or translate this signal into commands for moving SPMV 120U.

FIG. 10 is a flow chart of a routine whereby the computer providesdirect commands to the computer SPMV 120C according to electronic outputof game strategy engine in order to attempt to achieve one or more gameobjectives for computer SPMV 120C.

In FIG. 10, one or more objects (including, for example, user SPMV 120U)may move in the ‘real world.’ Step S159 is as in FIG. 7.

In step S619, direct commands are generated S619 for computer SPMV (i)in accordance with game objective(s), the Euclidan state of the sceneand/or data of an additional game data structure and; (ii) in responseto the detected movement of any object in the scene (e.g. user SPMV,game prop such as ball 114 or any other object). In some embodiments,the movement is detected by analyzing electronic image(s) and effectingmultiple Euclidian scene reconstructions (a first scene reconstructionat a first time a second reconstruction at a later time)—it is possibleto detect movement or angular displacement according to the two scenereconstructions.

In step S623, the computer SPMV 120C effects the direct command (forexample, to move, to fire, etc)—for example, according to the output ofgame strategy circuitry.

Although the user's moves may be said to have ‘influence’ upon motion ofcomputer SPMV 120C (since the computer SPMV 120C may be programmed to inresponse to any movement of objects in the scene—thus, SPMV 120C may beable carry out ‘countermeasures’ in response to the actions of user SPMV120U), it is clear that the relation between the user 102 and user SPMV120U (which operates primarily according to direct commands provided bythe user via user input device 102) is profoundly different from therelation between the user 102 and computer SPMV 120C.

A Discussion of a Technique for Operating an SPMV According toElectronic Images of the SPMV that Describe an Illumination Transitionof One or More Onboard Lights

Embodiments of the present invention relate to a SPMV 120 that includesa plurality of onboard lights (for example, see elements 124A-124D ofFIGS. 2B, 3B, 11A) that are mounted to the housing of the SPMV 120. Aswill be explained in the present section, it is possible toelectronically control of the onboard lights 124 to turn the light(s) onor off and/or modify their brightness and/or modify their color.Analyzing electronic images describing the ‘illumination transitions’produced by turning light(s) on or off and/or modifying color and/ormodifying brightness may be useful for facilitating: (i) the determininga ‘real-world’ or Euclidian location of the onboard lights 124themselves within a real-world scene captured by an image of the sceneacquired by the observing camera 110 where the image includes the SPMV120 and its immediate or nearby surroundings (see FIGS. 11-12 and stepS923 of FIG. 13); and/or (ii) the operating of the SPMV according to thereal-world or Euclidian locations (see FIGS. 13-16B); and/or (iii) thegeneration of camera calibration data including extrinsic calibrationdata for the observing camera (see FIG. 18A and FIG. 19); and/or (iv)the generation of calibration data for a SPMV motor and/or servo motor(see FIG. 18B).

In some embodiments, the SPMV 120 may be operated primarily according toinformation provided in images generated by observing camera 110—forexample, according to a Euclidian location of SPMV 120 (or a portionthereof). In some embodiments, this may be obviate the need for anadditional location-finding system (i.e. other than a system based onimages of the observing camera 120), such as an ultrasound locatingsystem or a radar-based locating system. In some embodiments, the SPMV120 is operated in accordance with (i) the Euclidian location of SPMV(or a portion thereof) as determined according to illuminationtransitions and (ii) other information available in the scene includingthe SPMV that is described by the image acquired by observing camera110.

Before explaining routines for utilizing illumination transitions tooperate SPMV 120 (i.e. control translational or rotational movement ofSPMV or of a portion thereof), several concepts are now explained:illumination transitions (see FIGS. 11A and 17), pixel locations of alight (see FIG. 11B), and extrinsic calibration data (see FIG. 12).

FIGS. 13-16B relate to the exemplary technique for controlling movement(or otherwise operating) the SPMV 120 according to information derivedfrom imaged illumination transitions (e.g. how the illuminationtransitions facilitate the determination of a Euclidian location of SPMV120 or a portion thereof).

FIGS. 18A-19 (and some other figures) relate to ‘self-sufficient’embodiments where it is possible to calibrate the observing camera 110and/or onboard motor of the SPMV 120 and/or a motor of a servo assembly112 using the same SPMV 120 which is to be later controlled accordingone or more mapping functions (i.e. associated with camera and/or servomotor and/or SPMV motor calibration) created by the calibration process.

This ‘self-sufficient’ approach obviates the need for a specialcalibration object (i.e. or the need to effect any calibration procedurethat requires a relatively ‘high’ degree of technical competence by user102) and allows for the distribution of relatively simple systems thatemploy a minimal number of components.

Thus, in some embodiments (for example, see FIGS. 18A-19), informationdescribing illumination transitions is employed to compute calibrationdata for an observing camera 110 (see FIGS. 12 and 18A) and/or for oneor more onboard motors powering SPMV 120 (see FIGS. 24A and 23) and/orfor a motor of a servo (see FIGS. 24B and 22B) on which a camera ismounted (i.e. for embodiments where the servo is part of thesystem—there is absolutely no requirement to employ any servo, howeverservo(s) are useful for some embodiments).

A Discussion of Illumination Transitions

Before describing the technique for controlling movement of roboticSPMVs 120 according to ‘illumination transitions’ of one or more onboardlights 124 mounted onto an SPMV 120, it is useful to discuss the conceptof illumination transitions. This concept will first be explainedrelative to a simple non-limiting example illustrated in FIGS. 11A-11B.

In FIG. 11A, in FRAME 1 (at time t₁), no lights are illuminated; inFRAME 2 (at time t₂), only light 124A is illuminated; in FRAME 3 (attime t₃), only light 124B is illuminated; in FRAME 4 (at time t₄), onlylight 124C is illuminated; in FRAME 5 (at time t₅), only light 124D isilluminated.

By turning on the light 124A, SPMV 120 is said to undergo anillumination transition TRANS₁ between the time of FRAME 1 and the timeof FRAME 2 (and illumination transition TRANS₁ relates only to a singlelight 124A); by simultaneously turning off light 124A and turning onlight 124B, SPMV 120 is said to undergo an illumination transitionTRANS₂ between the time of FRAME 2 and the time of FRAME 3 (andillumination transition TRANS₂ relates to lights 124A and 124B); bysimultaneously turning off light 124B and turning on light 124C, SPMV120 is said to undergo an illumination transition TRANS₃ between thetime of FRAME 3 and the time of FRAME 4 (and illumination transitionTRANS₃ relates to lights 124B and 124C); by simultaneously turning offlight 124C and turning on light 124D, SPMV 120 is said to undergo anillumination transition TRANS₄ between the time of FRAME 4 and the timeof FRAME 5 (and illumination transition TRANS₄ relates to lights 124Cand 124D).

In the simplified example of FIG. 11A, illumination transitions relatedonly to various embodiments, illumination transitions may relate tomodifying light brightness and/or light color. It is appreciated thatturning the light on or turning the light off (as illustrated in FIG.11A) is a particular case of the more general concept of “modifyinglight brightness.”

A Discussion of Pixel Locations

By effecting a subtraction between frames, it is possible to determine apixel location of one or more onboard lights 124. In the example of FIG.11A, the images of all frames are substantially identical with theexception of the pixels at the onboard light(s)—this is because thelocation and orientation or the SPMV 120 relative to observing camera110 is identical in all frames, and the only deviation between theimages relates to different ‘illumination configurations’ of the onboardlights 124.

The “difference images” are illustrated in FIG. 11B—these images areobtained by subtracting one frame from another frame, for example on a‘pixel-by-pixel’ basis (e.g. it is possible to subtract the intensity ofeach pixel in a first frame/image from the intensity of thecorresponding pixel in a second frame/image). As is illustrated in FIG.11B, it is possible to determine the pixel location of an individualonboard light by comparing pairs of images. It is noted that imagesubtraction is only one example of an image comparison.

In the event that the images of any image pair whose constitutive imagesare compared substantially identical images (i.e. identical in allaspects except for appearance deviations associated with a illuminationtransition(s),), it may be useful to subtract images when comparing apair of images (IMG_(PRE), IMG_(POST)), where IMG_(PRE) describes theappearance of the SPMV including the onboard lights 124 before a givenillumination transition, and IMG_(POST) describes the appearance of theSPMV including the onboard lights 124 after a given illuminationtransition—for the example of TRANS₁, it is possible to write that FRAME1 is a IMG_(PRE) and FRAME 2 is a IMG_(POST).

The deviation between frames (illustrated in FIG. 11B) that are causedby illumination transition (i.e. the change of light brightness and/orcolor for one or more onboard light(s)) may appears as an entire singlepixel or a ‘cloud’ comprising more than one pixel and/or with all pixelsin the cloud have the same deviation value or a range of values.

For the present disclosure, a “pixel location” refers to either (i) asingle pixel; (ii) a portion of a single pixel; and (iii) a centroid ofa group of more than one pixel (for example, weighted by brightness ordarkness or color). The “pixel location” refers to a position in theimage space and not to a position in world space.

In some embodiments, it may be preferred that the length and width ofthe cloud of pixels are on the same order of magnitude.

As noted above, the “image comparison” routine employed in FIG. 11B wasa simple image subtraction. Nevertheless, it is noted that imagesubtraction (used to generate FIG. 11B) is not the only possible type ofimage comparison that may be used. In embodiments where IMG_(PRE) andIMG_(POST) deviate due to relative translational or rotational motion ofthe camera and/or SPMV 120 (or a portion thereof), it may be useful,when effecting the image comparison, to first employ motion detectiontechniques to transform one of IMG_(PRE) and IMG_(POST) into‘transformed image’ which is substantially identical to the other ofIMG_(PRE) and IMG_(POST). In one use case, the SPMV 120 is intranslational and/or rotational motion during the illuminationtransition and thus has a different location in (R, Φ) space inIMG_(PRE) and IMG_(POST).

Motion detection or motion estimation techniques are well-known in theart and are used extensively in, for example, video compression.

It is possible to subtract this transformed image (i.e. transformed toreverse a change in location/orientation between camera 110 and SPMV120—for example, due to mechanical motion of camera 110 or SPMV 120)from one of IMG_(PRE) and IMG_(POST) in order to obtain a pixel locationof one or more onboard lights.

Camera Calibration Data

FIG. 12 shows a map between individual pixels and manifolds within thereal world (for example, lines). This mapping is defined by the cameracalibration data including extrinsic calibration data.

As will be discussed below with reference to FIGS. 13-16, it is possibleto use this camera calibration data (for example, in step S923 of FIG.13 or FIG. 16A) in order to (i) determine a real-world Euclidianlocation of one or more onboard lights 124; (ii) regulate movement ofthe SPMV 120 in accordance with the determined real-world location.

In some embodiments, because the mapping between “points in pixel space”on the left hand side of FIG. 12 an multi-point manifold on the righthand side of FIG. 12, it may be useful to employ other information whendetermining which point in Euclidian space matches a particular pixel.In one non-limiting example, information relating to an known orestimated height of an onboard light 124 above the floor.

The skilled artisan is referred to the section “Details of a SpecificExemplary Embodiment” below for additional details about hownon-limiting examples for computing the real-world Euclidian locationfrom a pixel location.

A Discussion of an Exemplary Routine for Operating an SPMV

FIG. 13 is a flow chart of a routine for operating (e.g. controllingmovement) of an SPMV 120 according to a Euclidian location detected froma respective pixel location of each onboard light 124 of one or moreonboard lights. FIG. 13 is discussed also with reference to FIGS. 14-15.

In FIGS. 14A-14E it is assumed that t₂ occurs at a time later than t₁,t₃ occurs at a time later than t₂, and t₄ occurs at a time later thant₃.

In step S901 of FIG. 13 (and as illustrated in FIG. 14A), the observingelectronic camera is operated to acquire an image at a time t₁. In theexample of FIG. 14A, this describes the vacuum cleaner SPMV 120 when noonboard lights are illuminated. This image will be referred to asIMG_(PRE).

In step S905 of FIG. 13 (and at time t₂—see FIG. 14B), a wirelesscommand is sent from computer unit 108 to SPMV S905 instructing the SPMVS905 to undergo an illumination transition. In the example of FIG. 14B,this command is a command to ‘turn on light 124C.’

In step S909 of FIG. 13 (and at time t₃—see FIG. 14C), the onboardelectronic circuitry (e.g. of SPMV electronic assembly 84—see FIG. 5)receives this command (for example, using an onboard wireless receiver)and executes this command to turn on light 124C. Thus, the time of the‘illumination transition’ is t₃.

In step S913 of FIG. 13, the observing electronic camera acquires and attime t₃—see FIG. 14C) an additional image—this image will be referred toas IMG_(POST).

The image of step S901 is acquired at time t₁, and describes theappearance of SPMV before the illumination transition which occurs attime t₃—therefore, the image of step S901 is referred to as IMG_(PRE).Before the illumination transition which occurs at time t₃ in step S909illustrated in FIG. 14C, illumination state Ii (in illumination stateI₁, no onboard lights are illuminated) prevails—it is this illuminationstate which is described in IMG_(PRE).

The image of step S913 is acquired at time t₄, and describes theappearance of SPMV after the illumination transition which occurs attime t₃—therefore, the image of step S913 is referred to as IMG_(POST).After the illumination transition which occurs at time t₃ in step S909illustrated in FIG. 14C, illumination state I₂ (in illumination stateI₂, only light 124C is illuminated) prevails—it is this illuminationstate which is described in IMG_(POST).

In one example, IMG_(PRE) and IMG_(POST) are substantially identicalexcept for features related to the illumination transition (i.e.IMG_(PRE) describes illumination state I₁ and IMG_(POST) describesillumination state I₂).

In step S917 of FIG. 13, IMG_(PRE) and IMG_(POST) are compared todetermine a respective pixel location of each onboard light 124 of oneor more lights. In one example, the comparison may include an imagesubtraction. —see, for example, the discussion above with reference toFIG. 11B. In the example of FIG. 14, step S917 is carried out incomputer unit 108—for example, by software executing on computer unit108.

In step S923 of FIG. 13, a real-world Euclidian location is determinedfor each onboard light 124 involved in the illumination transition ofstep S909—in the example of FIG. 14, only a single light (i.e. 124C) isinvolved in the illumination transition. However, embodiments of thepresent invention relate to ‘multi-light’ illumination transitions whena plurality of onboard lights 124 are involved in an illuminationtransition (see the discussion below with respect to FIG. 17). In theexample of FIG. 14, step S923 is carried out in computer unit 108—forexample, by software executing on computer unit 108.

In step S931 of FIG. 13, movement of the SPMV is controlled according tothe determined real-world locations. In the example of FIG. 14,controlling the robot includes generating and wirelessly transmitting acommand to SPMV 120—for example, a command to accelerate or decelerateor SPMV 124, or a command to move SPMV 120 to a particularEuclidianly-defined real-world location, or to a command to move SPMV120 to a particular Euclidiantly-defined real-world orientation, or tomove at a particular Euclidiantly-defined real-world speed, or to rotateat a particular Euclidiantly-defined real-world rotation rate.

An Additional Discussion Describing Some Exemplary Implementations ofStep S931

In one use-case related to step S931 (this relates to ‘example 1’ ofFIG. 15), the distance between the SPMV 120 and an obstacle (forexample, a table or sofa in FIG. 1 or any other possible obstacle) maybe determined according to the Euclidian location of the onboard lightmounted on the SPMV 120 (which may indicate the location and/ororientation of SPMV 120). According to this use case, in response to thedistance (or a change in distance) between the car and the obstacle (andthus in response to determined in step S923 of the Euclidian) location,it is possible to control movement of SPMV 120—for example, to (i) steerthe SPMV 120 to the left or right, (ii) to reverse distance of the SPMV120 or to (iii) decelerate or stop SPMV 120 in order to miss theobstacle.

In another use-case related to step S931 and FIG. 1 (this relates to‘example 1’ of FIG. 15), the distance between computer robot 120C and anobject other than an obstacle (for example, a game prop such as ball114) may be determined according to the Euclidian location of the anycombination of onboard light(s) 124 (as determined in step S923). Inthis use case, if the computer SPMV 120C gets within a certain distanceof ball 114, robotic arm 106C may move in response. Thus, it is possibleto operate a mechanical robotic appendage according to distance betweenSPMV 120C and a foreign object.

Another use case (this relates to ‘example 1’ of FIG. 15) relates to arobotic “butler” or “servant” SPMV 120 serves a drink to a person. Inthis example, the robotic butler SPMV 120 whose base is currentlystationary may rotate its mechanical arm as the robotic butler SPMV 120serves the drink. In this use case, a dog suddenly moves close to the‘rotating butler.’ Continued rotation would cause a collision betweenthe robotic arm holding the drink and the dog. Thus, in this use case,the information from the Euclidian location of the onboard light(s) 124derived in step S923 may provides an indication of the orientation ofthe robotic arm of the robotic butler SPMV 120, and hence may provide anindication of the rotational distance (or rotational displacement—forexample, in degrees or gradients) between the robotic arm and theforeign object (for example, an obstacle such as a dog). In step S931,the robotic arm would be operated accordingly.

Another use case (this relates to ‘example 1’ of FIG. 15) relates to arobotic forklift approaching its load. The distance between the tongs ofthe forklift and the load may be determined according to the Euclidianlocation of the light(s) of step S923. In this example, upward motion ofthe tongs is contingent upon the forklift being “close enough” to theload to lift the load. The distance between the tongs of SPMV 120 andthe load may be determined according to the Euclidian location of one ormore lights as determined according to earlier steps preceding stepS931. Thus, in this example, the operation of the forklift may be saidto be carried out according to the Euclidian location of one or morelights as determined according to earlier steps preceding step S931.

Another use case relates to motion control. In this example, an SPMV 120is attempting to move from a first location (for example, computergoalpost 118C of FIG. 1) to a second location (for example, usergoalpost 118U of FIG. 1). In this example, use of inexpensive andunreliable mechanical components (e.g. onboard SPMV motor(s), wheels ofSPMV 129) within SPMV 120 may cause SPMV 120 to cause SPMV to moveslightly to the left or slightly to the right instead of straight ahead.In this example, in step S771, the ‘pattern’ of motion to the left orright is detected, and in step S775, in response to this pattern iscorrected—for example, by steering SPMV 120 in the direction opposite ofits ‘biased’ direction (i.e. if SPMV 120 moves forward and slightly tothe left, corrective action of step S775 may cause SPMV 120 to moveforward and slightly to the right to compensate).

FIG. 15 indicates examples of step S931 in accordance with someembodiments. The left side of FIG. 15 describes a first example and theright hand side of FIG. 15 describes a second example. According to thefirst example, in step S761 a displacement or distance (eithertranslational or rotational or configurational distance) between SPMV120 (or a portion thereof) and a foreign location is determinedaccording to the Euclidian location of any light(s) that was determinedin step S912. In step S765, the SPMV 120 is operated according to thedetermined distance or displacement (i.e. either translationalrotational or configurational) determined in step S761.

According to the second example (see the right hand side of FIG. 15), instep S771, according to the Euclidian location of any light(s) (i.e. asdetermined in step S923 of FIG. 13), a time derivative of displacement(e.g. linear or angular velocity or acceleration) may be determined (seethe above discussion of the SPMV which veers to the left or right).

In some of the above examples, the ‘operating’ of step S931 includedsending a wireless command to SPMV 120. However, this is not alimitation. In yet other embodiments, the command may be sent via a datacable. In yet other embodiments, one or more of steps S905 and/or S931are carried out within SPMV electronic assembly 84, and the command maybe generated within SPMV 120.

An Additional Discussion of Step S931

As is evident from the examples discussed above, in some embodiments, instep S931 the SPMV 120 may be operated (e.g. to control rotational ortranslational movement of SPMV of a portion thereof) according to aEuclidian relationship (for example, a distanced between, an anglebetween, a rate of change of distance or angle, etc) between (i) SPMV120 (or a location on SPMV 120); and (ii) a ‘foreign object’ other thanSPMV 120 (for example, another SPMV or a prop or any other object)and/or a Euclidian location or locations (for example, a boundary suchas the ‘out-of-bounds’ boundary 96 in the soccer game depicted in FIG.1).

Thus, some embodiments relate to utilizing the combination of (i) theEuclidian location of one or more lights that undergo an illuminationtransition as described in a plurality of images of the scene includingthe SPMV 120 having onboard lights 124; and (ii) other informationdescribing other objects in the scene as recorded in the electronicimage(s) acquired by observing camera 110.

Examples of the ‘other information’ includes but is not limited tolocation or orientation information for the other object, shapeinformation describing the foreign object or boundary, heightinformation describing the foreign object or boundary, color or surfacetexture information for the foreign object, and motion informationdescribing translational or rotational motion of the foreign object.

In some non-limiting embodiments, in order to detect the location or anyother aspect of the ‘foreign object’ within the scene image includingSPMV 120 acquired by the observing camera(s), one or more the followingtechniques may be employed (i.e. either any single technique or anycombination or multiple techniques):

A) information from a plurality of cameras 110 viewing the same scene(for example, cameras 110A and 110B of FIG. 1 of 3) from differentperspectives—this image may include 3D or ‘stereoscopic’ data derivablefrom the plurality of images where each image is acquired by a differentrespective camera. In some embodiments, it may be assumed that allobjects in the scene are placed on ‘the floor,’ and when the ‘height’ asdetected by the plurality of camera(s) 110. Thus, in some embodiments,step S931 is carried out in accordance with the both (i) the real-worldEuclidian location determined from analyzing illumination transition inthe images of the scene including the SPMV 120; and (ii) stereoscopicand/or 3D image information derived from multiple images of the scene.B) in some embodiments, it may be difficult to detect where a givenforeign object is (e.g. because it is a ‘difficult’ image processingproblem). Nevertheless, if the foreign object (e.g. ball 114 in FIG. 1)moves, then it may be possible to effect some sort of motion-detectionroutine in order to detect the location of the foreign object. Thus, insome embodiments, step S931 is carried out in accordance with the both(i) the real-world Euclidian location determined from analyzingillumination transition in the images of the scene including the SPMV120; and (ii) results of motion detection of a foreign object.C) manual input for the user—in some embodiments, the user may manuallyprovide information describing the real-world location of variousforeign object (i.e. obstacles) in the scene—for example, describing thereal-world size of the foreign objects and/or the real-world distancebetween the foreign objects and/or a pre-determined real-worldtrajectory in which any foreign object will translate or rotate. Thus,in some embodiments, step S931 is also carried out in accordance withthis information.

In a non-limiting example, a software application executing on acomputer 108 may provide a user interface for receiving this manualinput. This user interface may include a visual description of the sceneeither as (i) the image taken by the camera unmodified (ii) acombination of images stitched together as is known in the art (iii) a3D graphic representation of the room as calculated from thestereoscopic or other calculation. The user may then be prompted to drawon the screen locations or lines or interest or may be prompted torespond to a question regarding a highlighted area.

A Discussion of Techniques for Controlling Camera 110 and OnboardLighting 124

In steps S901 and S913, images are acquired by observing camera(s) 110.In some embodiments, an explicit command may be sent from computer unit108 to camera 110 for the purpose of acquiring the image at theappropriate time. After the command of step S901 is sent computer unit108 to camera 110 to acquire IMG_(PRE), a different command is sent fromcomputer unit 108 in step S905 to induce the illumination transition.After time is allowed for the illumination transition to be carried outat SPMV 120 (or alternatively, after an acknowledgment of theillumination transition is received back), in step S913 it is possibleto send an additional command to camera 110 (for example, in response toan acknowledgement of the illumination transition wirelessly received bycomputer unit 108 from SPMV 120—thus the image acquisition of step S913may be in response to the illumination transition).

Thus, the ‘command scheme’ implementation for instruction the cameradiscussed with reference to FIG. 13 is just one way of obtaining a timeseries of images of the scene including SPMV. In the example of FIG. 13,the time series includes IMG_(PRE) acquired according to the command ofstep S905 and IMG_(POST) acquired according to commands of step S905 andS913,

It is noted, however, that there is no requirement that commands beprovided to camera 110 and/or onboard lighting 124.

In one non-limiting use case, camera 110 may be a video camera and eachimage may be associated with a time stamp. In this use case, computerunit 108 (or any other electronic circuitry or logic managing theprocess of FIG. 13 or 16A or 16B) may obtain each video frame with somesort of time stamp. If computer unit 108 (or any other electroniccircuitry or logic managing the process of FIG. 13 or 16A or 16B) is‘aware’ of the time of the illumination transition, it may be possibleto select from the video frames images for IMG_(PRE) and IMG_(POST).This may require correlating the image acquisition times for camera(s)110 with an illumination transition time of onboard lighting 124.

In some embodiments, the illumination transition time may be determinedaccording to the time a command is sent to SPMV (for example, see stepS905 of FIG. 13). Then, the selecting of IMG_(PRE) and IMG_(POST) may becarried out so that the image acquisition time by camera 110 ofIMG_(PRE) precedes the image acquisition time by camera 110 ofIMG_(POST).

Alternatively, there is no requirement to send a wired or wirelesscommand to induce the illumination transition. In some embodiments,onboard lights 124 may be ‘internally configured’ (for example, SPMVelectronics assembly 84 may be internally configured without requiringany external input from outside of SPMV 120) to automatically undergoone or more illumination transitions—for example, at pre-determinedtimes (e.g. according to some periodic blinking pattern other with someother pre-determined temporal scheme).

In one example when it is ‘known’ or ‘predicted’ that an imagetransition will occur at a particular time t_(given), then it ispossible to acquire in IMG_(PRE) and/or IMG_(POST) ‘response’ to thisinformation about the timing of the illumination transition att_(given). In another example, camera(s) 110 may be configured torepeatedly acquire images of the scene (for example, in ‘video cameramode’) and images may be designated as IMG_(PRE) and/or IMG_(POST)according to time stamps of the image and information about theillumination transition at t_(given).

A Discussion of FIGS. 16A-16B

FIGS. 16A-16B are flow charts of routines for operating an SPMV 120according to a Euclidian location of an SPMV (or a portion thereof) asdetermined

The routine of FIG. 13 is one particular ‘use-case’ example of theroutines of FIGS. 16A-16B.

In step S711, camera calibration data including extrinsic calibrationdata (see, for example, the map of FIG. 12) for one or more observingcamera(s) is provided. Routines for determining the camera calibrationdata including extrinsic calibration data are discussed below withreference to FIGS. 18-19.

In step S715, one or more onboard lights 124 of SPMV 120 areelectronically controlled to modify color and/or brightness to effect anillumination transition trans. In one example, this is carried out bysending wireless commands (see steps S905-S909 of FIG. 13). In anotherexample, the onboard lights 124 operate autonomously with no need forexternal input from outside of SPMV 120 (for example, according to somepre-determined timing scheme).

In step S719, a time series of images is acquired, including IMG_(PRE)and/IMG_(POST). In some embodiments, this is carried out in steps S901and S913 of FIG. 13. In another embodiment as discussed above, camera110 may automatically acquire a time series of images (i.e. withoutreceiving explicit instructions via an incoming data communication), andIMG_(PRE) and/or IMG_(POST) may be selected according to a ‘temporalcalibration’ as discussed above. Steps S917-931 are as discussed above.

Reference is now made to FIG. 16B. Step S719 is the same as in FIG. 16A.In step S937, the real-world Euclidian location of one or more onboardlight(s) 124 is determined according to an illumination transitiondescribed by trans—for example, according to steps S715 and S917-S923 ofFIG. 16A. Step S931 is as described above.

A Brief Discussion of FIG. 17

FIG. 11A described certain illumination transitions. One salient featureof the illumination transitions is that each transition only involved atmost a single light transitioning from ‘off’ to ‘on’ and at most asingle light transitioning from ‘on’ to ‘off.’ This is just an example.As shown in FIG. 17, any illumination transition may involve any numberof onboard lights.

A Discussion of a Technique for Operating an SPMV in a Field of Field ofan Observing Camera in a ‘Self-Sufficient’ Manner

FIGS. 18A-18B are flow charts for techniques for ‘self-sufficient’systems where (i) an SPMV 120 is operated according to a Euclidianlocation of one or more onboard lights 124 as determined from images ofthe SPMV 120; and (ii) the system does not require any calibrationobject. FIGS. 18A-18B assumes that the geometry of how the onboardlights 124 are deployed is known a-priori—i.e. that ‘real-world’Euclidean distances between onboard lights 124 and/or Euclidean anglebetween line segments connecting the onboard lights 124 are known.

Instead of requiring an external calibration object and/or the presenceof trained technicians, the systems of embodiments of FIGS. 18A-18B are‘self-sufficient’ such that calibration data may be calculated accordingto a time series of images of the SPMV 120 itself. In some embodiments,SPMV 120 include one or more onboard lights 124 which are electronicallycontrolled to undergo illumination transition(s). Comparison ofpre-illumination-transition images (i.e. images of the scene includingthe SPMV that are acquired before respective illumination transitions)with post-illumination-transition images (i.e. images of the sceneincluding the SPMV that are acquired after respective illuminationtransitions) may be useful for computing calibration data of (i) anobserving camera and/or (ii) a servo motor of a servo assembly 112 onwhich a camera is mounted (i.e. for those embodiments that include aservo assembly 112—as noted above this certainly not a requirement);and/or (iii) an onboard motor of an SPMV 120.

Thus, in step S1011 of FIGS. 18A-18B, respective pixel locations ofonboard lights 124 may be determined by comparingpre-illumination-transition images with post-illumination-transitionimages. In step S1015, it is possible to calculate calibration data fromthe combination of (i) pixel locations of multiple onboard lights 124(for example, at least four non-planar onboard lights 124 or at leastsix onboard lights) and (ii) known real-world Euclidian distancesseparating the lights and/or known Euclidian.

The skilled artisan is referred to the section “Details of a SpecificExemplary Embodiment” below for additional details about hownon-limiting examples for computing the real-world Euclidian locationfrom a pixel location.

The routines of FIG. 18-20 are automatic—i.e. the illuminationtransitions are carried out automatically by electronically controllingthe electronic lights, and (if relevant) servo assembly 112 and/or SPMV120 operate automatically to mechanically change the distance betweencamera 110 and/or SPMV 120 and/or the angle of SPMV 120 (or a portionthereof) relative to camera.

In FIG. 18B, step S1015 is generalized into step S1015′ wherecalibration data may be computed for the camera 110 and/or a servo motorof any servo assembly 112 and/or an onboard SPMV motor.

The techniques of FIGS. 18A-18B do not require any mechanical motion insteps S1011-S1015 (or S1011-S1015′) and may rely exclusively on ananalysis of illumination transitions. Thus, in some embodiments, therelative location of SPMV 120 (and constitutive parts) relative tocamera 110 may remain constant during S1011-S1015 (or S1011-S1015′).

Nevertheless, experiments conducted by the present inventor haveindicated that the quality of calibration may be improved (evendramatically, in some situations) by mechanically moving SPMV 120 and/orcamera 110 (for example, using servo assembly 112) during calibration.Techniques for carrying this out are discussed below with reference toFIG. 22.

FIG. 19 is one non-limiting implementation of FIG. 18B. In this example,multiple sets of calibration images are acquired and used in step S711″to compute calibration data. Thus, first a ‘first set’ of calibrationimages are acquired during a first pass of steps S1211, S1215 andS1219—these calibration images relate to multiple illuminationtransitions (for example, at least 3 illumination transitions) that alltake place when the SPMV 120 is located in a first location (R₁, Φ₁) in(R, Φ) space (e.g. there is no mechanical motion of camera 110 relativeto SPMV 120 while the ‘first set’ of calibration images is acquired).After the ‘first set’ of calibration images are acquired, in step S1223the SPMV 120 and/or camera(s) 110 are mechanically moved in step S1223so the location of SPMV 120 relative to camera 110 in (R, Φ) space is(R₂, Φ₂), and a second set of calibration images is acquired when theSPMV 120 is located in a second location (R₂, Φ₂) in (R, Φ) space—stepsS1211-S1223 may be repeated any number of times—for example, at least 5or 10 times. In step S1227, calibration data is computed by comparingcalibration images with each other according to illumination transitionsto determine pixel locations and to determine calibration data accordingto the known geometry of onboard lights 124.

A Discussion of (R, Φ) Space Describing the Position and/or Orientationof SPMV 120 (or a Portion Thereof) Relative to Camera 110

FIG. 20A-20D describe (R, Φ) space of the SPMV and/or a portion thereofrelative to camera 110.

FIGS. 20A-20B illustrates R space. FIG. 20C illustrates configuration ororientation space (Φ−space) In FIGS. 20A-B, the location of SPMV 120 inR space is designated by ‘locator point 118’ (for example, some sort ofcentroid of SPMV 120—the locator point in FIG. 20B differs from thelocator point in FIG. 20A). In FIG. 20C, SPMV 120 as a whole (which ingeneral is not radially symmetric) is oriented in differentorientations—3 orientations Φ₁, Φ₂ and Φ₃ are illustrated in FIG. 20C.In FIG. 20D, a component (e.g. a flag or any other portion or componentof SPMV 120) may have different orientations.

(R, Φ) space is the Cartesian product of R space and Φ−space.

Motion in (R, Φ) space (see step S1223 of FIG. 19) is illustrated inFIG. 21. Thus, FIG. 21A relates to the case of R-space motion of theSPMV. FIGS. 21B-21C relate to the case of Φ−space motion of the SPMV.FIG. 21C relates to the case of camera motion (and does not requiremechanical motion of SPMV 120)—in some embodiments, the camera motionmay be provided using servo assembly 112 on which a camera 110 ismounted.

Any combinations of the motions modes may be provided (for example, instep S1223).

A Discussion of Servo(s) Assemblies 112

In step S1015′, it is discussed that it is possible to generate servocalibration data and to utilize this calibration data when determining aEuclidian location of SPMV.

In the present sections, servo assemblies 112 are discussed for theparticular non-limiting case where there are two cameras 110 each camerabeing mounted on a respective servo assembly. In other embodiments,there may only be a single camera mounted on a single servo assembly. Inother embodiments (not shown), in order to save manufacturing costs, itis possible to provide multiple cameras on a single servo assembly.

Thus, as is illustrated in FIGS. 1, 3, in some embodiments camera 110may be mounted on a pan-and-title system 108 (i.e. a servo) as a cameraassembly 92. Mounting the camera 110 onto a servo may obviate the needto use a ‘more expensive’ wider-view camera and may also be useful forcalibrating camera 110 according to images of SPMV 120 (the discussionabove).

FIG. 22A illustrates two camera assemblies 92A, 92B including twocameras 110A, 110B and respectively mounted on respective servoassemblies 112A, 112B. A first camera 110A is mounted on a firstpan-and-tilt system (or ‘servo assembly’) 112A which includes two servomotors. A first servo motor 3 rotates the tilt system 4 about the y axisas shown in the coordinate axis shown in the diagram. A second servo 4motor drives the tilt system which rotates the camera 1 about the xaxis. The system (i.e. combination of servo assembly 112 and camera 110)can thus view a large area of the room—for example, when it is placed inroughly corresponding to the hemi-sphere forwards of the z axis.

In one implementation, both the camera 110 and the pan-and-tilt system(referred to throughout the present disclosure as a ‘servo assembly’)112 are controlled and powered by a first camera control unit (CCU) 5(e.g. corresponding to camera electronics assembly 80) to which thecamera and servo are attached by direct wiring. The CCU 5 (or cameraelectronics assembly 80) is an example of electronic control circuitry130 and may be implemented in any combination of hardware, software andfirmware. In the exemplary embodiment the CCU 5 may include some basiccomputational capability in the form of microcontrollers and memory. Insome embodiments, CCU 5 is capable of providing the signals required todirect the servo motors 3 and 4 of servo assembly 112 and the camera110.

In some embodiments, CCU 5 may include volatile and/or non-volatilememory for storing an image acquired by camera 110. For example, the CCU5 may receive the camera image, process it to some extent and capable ofstoring the processed or unprocessed image (in and before communicatingdata of the image (i.e. either wireless communication as shown in FIGS.1, 3 or wired communication) to other computing devices (for example,computer unit 108 or any SPMV 120). Thus, the first camera assembly 92Amay includes the first camera 110A, the first pan and tilt system 112Aand the first CCU 5.

A second camera assembly 92B may include camera 110B placed on a secondpan-and-tilt system 112B (or ‘servo assembly’) which operates in thesame manner as the as the first pan-and-tilt system 112A. Both thecamera 110B and the pan-and-tilt system 112 may be controlled andpowered by a second CCU 8. Thus, the second camera assembly 92B mayinclude the second camera 110A, the second pan and tilt system 112B andthe second CCU 8.

In one non-limiting embodiment the two CCUs 5 and 8 may be eachconnected by a data cable (for example a USB cable each) to a computerunit 108. However, in other embodiments the cable may be replaced by awireless connection with similar capabilities. In yet other embodimentsthe computer may be replaced be a mobile computing device, a dedicatedinterface unit, a router connected to a remote computer or network orany similar alternative. Any such controlling processing unit will bereferred to without precision as: the controlling computer. In any casethe cable or wireless interface is used to transmit images from thecamera to the controlling computer and is also used for the controllingcomputer to transmit instructions to the CCU.

A Discussion of Servo Motor Calibration Data with Reference to FIG. 22B

In some embodiments, any component of servo assembly 112 may berelatively inexpensive and/or not completely reliable. As such, it ispossible that when an image is acquired, that the location of SPMV 120in (R, Φ) space relative to camera 110 is not known or known withuncertainty.

For example, if the location is known at a certain point in time, butthen camera is moved (for example, tilted) by an unknown (or known withrelatively low certainty) angle, then at the later time the relativelocation or orientation of SPMV 120 relative to camera 110 may beuncertain. Towards this end, it may be useful to have ‘servo calibrationdata.’ Servo calibration data describes the relationship between: (i) aninput to motor(s) of servo assembly 112 (for example, a voltage orduring that a voltage is applied or any other input)—this is the ‘x’axis of FIG. 22B and (ii) a rotational displacement of servo assembly112 in response to the power input to the motor(s)—this is the ‘y’ axisof FIG. 22B.

If (i) before servo movement the position of camera 110 is known; and(ii) the amount of camera displacement (e.g. angular displacement)associated with a given amount of power is known (e.g. from the graph ofFIG. 22B), then it is possible to determine (e.g. with a ‘lower’ amountof uncertainty) the Euclidian location of SPMV 120 relative to camera110 using knowledge of the camera's previous location beforere-orientation of servo assembly 112.

It is noted that the Euclidian location of SPMV is always determinedrelative to the camera 110 (this may also be determined in an absolutelevel if the location of the camera 110 is known). Thus, knowledge aboutthe ‘Euclidian location’ of SPMV (for example, in FIG. 18B—for example,in accordance with determined pixel locations of lights that aredeployed with known geometry) gained by (i) effecting illuminationtransitions, (ii) acquiring PRE and POST images; and (iii) comparing thePRE and POST images to learn about pixel location and hence Euclidianlocation of light(s), may be useful for also helping to determineinformation the location of camera 110 (and hence information about aprevious camera displacement caused by servo motors). For example, it ispossible to leave SPMV 120 stationary and to move camera 110 using servoassembly 112.

Thus, the combination of (i) knowing about ‘power parameters’ for ‘inputpower’ to motor(s) of servo assembly 112; and (ii) knowing about howmuch camera 110 has moved relative to SPMV 112 since camera 110 was at aprevious known position (i.e. from knowledge of the Euclidian locationof SPMV 112 relative to camera 110 which is determined from pixellocations of lights) can be useful for computing servo motor calibrationdata in step S1015′. Since it is possible to obtain information aboutthe ‘current location’ of SPMV 120 in (R,PHI) space from knowledge ofthe Euclidian location of lights 124 (i.e. based on pixel locations oflights), comparing images in accordance with an illumination transitionsmay be useful for (i) determining camera 110 has moved or re-orientedsince servo motor(s) were subjected to known power parameters (e.g.input voltages); and (ii) thus, determining information related to theservo calibration curve (see FIG. 22B).

At a later time, it is possible that camera 110 has moved again (i.e.since the most recent calibration). In this case, it may be useful touse the servo calibration information (e.g. as in FIG. 22B) to determinehow much the camera 110 has moved, in order to determine, in step S1021,the Euclidian location of SPMV 120 relative to camera 110. As isdiscussed above (e.g. with reference to FIG. 15), knowledge of theEuclidian location of SPMV 120 relative to camera 110 can be useful foroperating (e.g. controlling motion of) SPMV 120.

A Discussion of SPMV Onboard Motor Calculation with Reference to FIG. 23

Similar reasoning may be used for the onboard motor(s) of SPMV 120.

Thus, embodiments of the present invention relate to techniques for (i)determining the relative Euclidian location in (R, Φ) space of SPMV 120relative to camera 110 and (ii) operating SPMV 120 according to thisknowledge of the Euclidian location in (R, Φ) space.

In some embodiments, when power is delivered to SPMV 120 onboard motors,it is not certain how far SPMV 120 moves—this is especially true if SPMV120 includes inexpensive or not completely reliable components. Inanother example, the friction parameters between SPMV 120 and the floormay not be known, or may vary depending on the surface of the flooring(e.g. carpet may be different from wood flooring). Since it is desiredto be able to determine the relative Euclidian location in (R, Φ) space,it is desired to know, after a known amount of voltage (or any otherpower parameter) is delivered to SPMV 120 onboard motors, how much theSPMV (or a portion thereof) has moved or re-oriented in response to thedelivery of power to SPMV onboard motors.

This relationship is illustrated in FIG. 23.

If (i) before SPMV movement the position of SPMV 120 relative to camera110 is known; and (ii) the amount of SPMV displacement (e.g.translational or angular displacement) associated with a given amount ofpower is known (e.g. from the graph of FIG. 22B), then it is possible todetermine (e.g. with a ‘lower’ amount of uncertainty) the Euclidianlocation of SPMV 120 relative to camera 110 even after the SPMV movesusing knowledge of its previous location before SPMV motion.

It is noted that the Euclidian location of SPMV is always determinedrelative to the camera 110 (this may also be determined in an absolutelevel if the location of the camera 110 is known). Thus, knowledge aboutthe ‘Euclidian location’ of SPMV (for example, in FIG. 18B—for example,in accordance with determined pixel locations of lights that aredeployed with known geometry) gained by (i) effecting illuminationtransitions, (ii) acquiring PRE and POST images; and (iii) comparing thePRE and POST images to learn about pixel location and also Euclidianlocation, may be useful for also helping to determine information ofSPMV 120 relative to the camera, and hence information about how farSPMV 120 has travelled since its position was last known and since SPMVonboard motors have operated.

Thus, the combination of (i) knowing about ‘power parameters’ for ‘inputpower’ to onboard motor(s) of SPMV 120 and (ii) knowing about how farSPMV 120 has moved or reoriented since SPMV 120 was in a previous knownposition in (R, Φ) space relative to camera 110 can be useful forcomputing onboard SPMV motor calibration data in step S1015′. Since itis possible to obtain information about the ‘current location’ of SPMV120 from knowledge of the Euclidian location of lights 124 (i.e. basedon pixel locations of lights), comparing images in accordance with anillumination transitions may be useful for (i) determining how far anSPMV 120 has travelled since being subjected to known power parameters(e.g. input voltages); and (ii) thus, determining information related tothe SPMV onboard motor calibration curve (see FIG. 23).

At a later time, it is possible that SPMV 120 has moved again (i.e.since the most recent calibration). In this case, it may be useful touse the SPMV onboard motor calibration information (e.g. as in FIG. 23)to determine how much the SPMV 120 has moved, in order to determine, instep S1021, the Euclidian location of SPMV 120 relative to camera 110.As is discussed above (e.g. with reference to FIG. 15), knowledge of theEuclidian location of SPMV 120 relative to camera 110 can be useful foroperating (e.g. controlling motion of) SPMV 120.

A Discussion of FIGS. 24A-24B

As noted above, knowledge of the servo motor and/or onboard SPMV motorcalibration curve (see FIGS. 22B-23) may be useful for determining, atany given time, the relative Euclidian location in (R, Φ) space of SPMV120 relative to camera 110. As noted above, this may be useful foroperating SPMV 120 (see, for example, the discussions with reference toFIG. 15).

FIGS. 24A-24B relate to additional routines for utilizing motorcalibration data.

In FIG. 20A, once the motor calibration data is known, if is desired tomove SPMV 120 a specified distance, it is possible to utilize the dataof the SPMV onboard motor calibration curve (see, for example, FIG. 23)in order to determine a power parameter for delivering power to SPMVonboard motor(s).

Similarly, in FIG. 20A once the servo motor calibration data is known,if is desired to reorient camera 110 by a specified angle, it ispossible to utilize the data of the servo motor calibration curve (see,for example, FIG. 22B) in order to determine a power parameter fordelivering power to SPMV onboard motor(s).

A Discussion of Operating Robots in an Outdoors Environment and/or anEnvironment with a Relatively Large Ambient Light Level

In some embodiments, when there is a relatively ‘high’ level of ambientlight, one or more onboard lights 124 may be difficult to detect fromimages acquired by camera 110. In this case, (or in other cases), it maybe desirable to replace any onboard lights with onboard mechanicalshutters.

For example, it is possible to have a black mechanical shutter (on SPMVhousing which conceals a white surface. The local surface of SPMV 120housing in the vicinity of the black mechanical shutter is also black.Thus, when the shutter is closed, the entire surface (i.e. including theshutter itself and the surrounding region) appears black—conceptually,this may be regarded as similar to a ‘light off’ illumination status.When the shutter is open, the surround region remains black but theviewed surface of SPMV 120 housing at the location of the shutter iswhite.

FIG. 25A illustrates the time development of a shutter 1310 as ittransitions (i.e. a shutter transition) from open to closed. In FIGS.25-26, the ‘shutterable region’ is referred to with number 1310 and thesurrounding region is referred to with number 1314—when the shutter isopen the status of the shutterable region is “O” status, when theshutter is closed, the status of the shutterable region is “C” status,and when the shutter is half closed the status of the shutterable regionis “H” status.

In FIG. 25A, both the color of the shutter itself as well as the colorof the surrounding surface 1314 of SPMV 120 housing is ‘color B’ (insome non-limiting examples, a ‘dark’ color such as black). The color ofthe ‘sometimes concealed’ surface (i.e. within shutterable region 1310)which is sometimes concealed by the shutter and sometimes revealed (i.e.when the shutter is open an in “O” status) is ‘color A.’ (in somenon-limiting examples, a ‘light’ color such as white).

FIG. 25B is the time development of a shutter as it transitions from“Closed” to “open.”

As is shown in FIG. 26, it possible to deploy multiple shutterassemblies 1301 at different locations (for example, with known geometryand known distances and angles between them—for example, in anon-coplanar configuration) on SPMV 120 housing.

FIG. 26 illustrates multiple shutter regions which may be in “O”configuration or “H” configuration or “C” configuration. The mechanicalshutter transitions (i.e. shutting or opening of shutters) aredesignated by MTRANS. Thus, MTRANS1 refers to the opening of the shutterof 1310A—i.e. the region which in FRAME 1 appeared dark now may appearlight. This may be considered equivalent to the “turning on” of a light.Close study of FIG. 26 in comparison to FIG. 11A indicates that they areanalogous—i.e. MTRANS1 of FIG. 26 is analogous to TRANS1 of FIG. 11A,MTRANS2 of FIG. 26 is analogous to TRANS2 of FIG. 11A, and so on.

Thus, in some embodiments, it is possible to substitute for any onboardlight 124 the combination of (i) specially colored shutter which mayconceal a region of a different color as discussed with reference toFIGS. 25-26. It is possible thus, to effect routines of FIGS. 13,16A-16B, 18A-18B, 19, 24A-24B using colored shutter regions 1310 insteadof and/or in addition to onboard lights, and effecting ‘shuttertransitions’ (for example, see FIGS. 25A-25B for examples of shuttertransitions) instead of ‘illumination transitions.’

In some embodiments, this may be preferred in an outdoor environment.

Discussion of FIGS. 27A-27B

Some embodiments of the present invention relate to a scenereconstruction translation layer 952 (for example, a softwaretranslation layer which resides in volatile or non-volatile memory andis executing by electronic circuitry such as a computer processor). Thesoftware translation layer 952 (i) receives Euclidian commands foroperating an SPMV 120 from a client application (for example, a gameclient application 806 in FIG. 27A or an inventory managementapplication 1806 in FIG. 27B) (for example, commands to move to acertain distance or to a certain location, to turn by a certain angle,etc); (ii) generates motor commands for robot/SPMV 120; (iii) repeatedlyeffects Euclidian scene reconstructions (for example, according toanalysis of pixel locations of onboard lights or analysis of imagesaccording to mechanical shutter transitions or according to othertechniques (i.e. without requiring lights or shutters)which facilitatedetermining a Euclidian location of any object of the scene; (iv)forwards this Euclidian description of the scene viewed by camera 110 tothe client hardware or client application (e.g. 806 of FIG. 27A or 1806of FIG. 27B).

Towards this end, scene reconstruction translation layer may employcamera and/or servo and/or motor calibration data to determine theEuclidian location of object(s) in the scene and/or to send commands toSPMV(s) 120 and/or servo assembly 112.

According to the architecture illustrated in FIGS. 27A-27B, the clientdevice or application can issue ‘abstract’ Euclidian directives to moveobjects within a ‘real-world’ scene without having to handle issuesrelated to scene reconstruction.

In FIG. 27A, a game client application 806 includes game strategy logicand game rule logic which operate according to the content of real worlddata storage 144 which is updated according to data received from scenereconstruction translation layer 952.

In FIG. 27B, the same scene reconstruction translation layer 952 may bereused to provide virtual world-real world interface functionality to aninventory management system which may management movement of inventoryby robots (i.e. robots or SPMVs may move around inventory) according toa strategy logic (e.g. which may optimize robot usage according tovarious ‘inventory objectives’ such as minimize restocking time, minimalwarehouse rent, minimizing SPMV power consumption, etc.

In some embodiment, scene reconstruction translation layer may beassociated a software or hardware component which provides‘self-sufficienty’ and automatically calibrates the camera and/or servoassembly and/or SPMV motor. This provides yet another way to “abstractaway the real world” from client hardware or application (e.g. 806 or1806).

FIGS. 28A-28B illustrate some routines that may be carried out bytranslation layer 952. Thus, FIG. 28A includes steps S911, S915, andS919. FIG. 27B also includes steps S921 and S923.

A Discussion of FIG. 28

FIGS. 29-30 relate to routines for determining a movement angledescribing angular movement of a camera due to servo assembly rotation.This may be useful for computing camera extrinsic calibration data (ie.from earlier more reliable camera calibration data describing the camerabefore it underwent a mechanical rotation.

Thus, FIGS. 30A-30B include steps S511, S515, S519, S523, S527, S551,S555, S559, S563 and S561.

Details of a Specific Exemplary Embodiment

In some embodiments, two cameras 110A and 110B (or more) are provided asparts of two camera systems 92A, 92B. These two camera systems 92A and92B (or more) may be placed on a roughly flat surface (see, for example,FIGS. 1 and 3) such that their viewing hemispheres include the SPMV 120and the scene of interest. In one embodiment, they need not be placedwith precision nor with any particular regard to the distance andrelative position between them. Nevertheless, in some embodiments, theaccuracy of the triangulation system to be described (i.e. forembodiments where a triangulation system is provided) may be reduced ifcamera systems 92A, 92B are placed less than a few centimeters apart. Inother embodiments a designer may choose to fix the exact positionbetween the camera systems. However, it is noted that, in manyembodiments such careful placement is not required—in these embodiments,no trained technician is required to place camera systems 92A, 92B,making the system suitable for home use or use by hobbyists. It isimportant to note that no direct measurement of the placement of the twocamera systems (92A and 92B) is required.

In some embodiments (for example, see FIGS. 1 and 3), SPMV 120 is placedin the scene of interest. The scene of interest might be the floor onwhich objects are placed which the SPMV is to interact with. These otherobjects of interest might be other, similar SPMVs, inanimate objectswhich the SPMV is required to grasp or move, components to beconstructed, things to be cleaned or painted or any such likealternatives. The floor might be some other, roughly flat, workingsurface or such like.

In one use case (see FIGS. 2B, 3B) SPMV 120 is a wheeled vehicle with anumber of LEDS placed around its body whose motors and LEDs arecontrolled by some processing capability built into the SPMV. Thisprocessing ability includes in one embodiment at least onemicrocontroller. The processing ability includes the ability to receiveand transmit at least simple wireless signals. In one example, aZigbee©-like protocol stack may be employed. In one embodiment, the CCU5 contains a wireless module of the same protocol capable ofcommunicating with the SPMV. In other embodiments the SPMV communicatesdirectly with the controlling computer. In such cases the wirelessprotocol would be chosen accordingly.

In some embodiments the SPMV 120 is equipped with a typicallyarticulated robotic arm 106 controlled by the processing capability ofthe SPMV 120 (for example, as provided by SPMV electronics assembly 84).In other embodiments there is no such robotic arm. In yet otherembodiments there may be some other moving equipment on the SPMV 120,lasers, range finders, ultrasound devices, odometers other sensors, oralternative equipment. Nevertheless, there is no requirement to includesuch additional sensors, and some embodiments tech operation of SPMV 120primarily according to analysis of images of the scene including SPMV120.

In some embodiments, SPMV 120 is designed with a generic mechanical andelectronic plug whose interface has been standardized and published suchthat third parties can design accessories for the SPMV 120.

Additional Discussion about System Calibration

Although not a requirement in some embodiments, electronic circuitry 130may include a computer unit 108 as illustrated in FIG. 1. In someembodiments, software executing on the controlling computer 108 can (i)operate the camera servo motors (e.g. to re-orient a camera 110), and/or(ii) receive images taken by the cameras, and/or (iii) move the SPMVand/or (iv) turn LEDs on and off on the SPMV. It can time and coordinatethese activities with timing precision.

As said, the setup of the system in terms of the placement of itscomponents can be haphazard and does not require skilled or trainedpersonnel. Once all components have been placed and plugged in or turnedon, the system must now learn from its environment the exact position ofits relative components and their intrinsic parameters. This is referredto as calibration of the system. Once calibration of the system has beencompleted, the 3D visual interface can be displayed and the SPMV guidedand controlled with the precision required by the specific application.

In order to calibrate a camera, a calibration object may be employed.Some embodiments teach that the calibration object is the mobile SPMV 10itself (for example, including onboard lights 124 or onboard mechanicalshutters). This may obviate the need to introduce or manipulate aspecial calibration object.

In the non-limiting example of FIG. 2A, SPMV 120 has 8 LEDs 124 placedaround it. In this example, these LEDs may be placed roughly as shown.For example, LEDs may be placed in at least three planes. In otherembodiments there are fewer LEDs. In yet other embodiments there can bemany more. In some embodiments, the position of each LED is known withsome precision (typically within millimeters) (see, for example, stepS1015 of FIG. 18A). Lights 124 need not be placed in exact positions(such as within a specific plane etc.)

An Discussion LED Positioning System (One Example of a‘Light-Transition’ Based Positioning System—See FIGS. 13-16)

One example of an implementation of step S917 (see FIGS. 13, 16A-16B) isdiscussed in the current section. It is appreciated that theimplementation details of this current example are not intended tolimit, but rather to explain one single use case.

LEDs provide a very fast and computationally easy method to find a spotin the image with a known world coordinate. Assuming no movement ofobjects in the scene or the camera, two succeeding images one with theLED off and one with the LED on can be compared (see the discussionwhich accompanies FIG. 11B).

In one example, the pixels that change (i.e. which are changedIMG_(POST) in relative to IMG_(PRE)) are potentially the result of theLED turning on or off. In one example, next an image is created that iscomposed only of the difference in intensity of the two images (assuminga gray scale image). In one example, next a convolution is performed toblur the image and add the intensity of neighbors to any given pixel.The pixel with the highest intensity may be considered the centroid ofthe LED flash (thus other techniques for locating a ‘centroid’ may beused). Using this method, in some embodiments, a few frames are requiredto locate all eight LEDs. In some embodiments, nine images are certainlyenough but there is a way of allowing multiple LEDs to flashsimultaneously while still recognizing each location. This may be doneby each LED flashing as if spelling a binary number. Using this method,5 frames may be sufficient. (1: none. 2: 1, 3, 5, 7 on. 3: 2, 3, 6, 7on. 4: 4, 5, 6, 7 on. 5: 8 on) this method provides far more significantresults for large numbers of LEDs. Typically, the CCU (FIG. 1 object 5)takes the images and transfers them to the controlling computer. (Thecomputation is actually simple enough for the microcontroller in the CCU(FIG. 1 object 5) to calculate the results without sending the image tothe controlling computer thus saving transfer time.) Finally, as will bedescribed soon, there are situation where two LEDs are sufficient toprovide the location and orientation of a SPMV.

In order to achieve good results when detecting flashes, it may beadvantageous to set the CCD camera settings to maximize the contrastbetween on an off. First of all, it may be advantageous for automaticgain control to be turned off. Secondly, it may be advantageous forbrightness to be set at lower than the level normally desirable forhuman viewing. This may be done by lowering brightness to the levelwhere the peak intensity in non-lit images are below 0.8. With thissetting bright LEDs cannot be confused for other changes and neither istheir reflection.

In some embodiments, it may be advantageous to mount LEDs 124 to SPMV120 by installing them somewhat inset into the surface or flush with itin order that the reflection of the light on the surface in theimmediate vicinity does not affect the calculation of the center-pointof the light.

A Brief Discussion of the Robustness Properties of this Method of UsingLEDs

This non-limiting ‘use-case’ system, specifically in the example justcited, relies on the comparison of two images one each of which has adifferent configuration of LEDs turned on or off. All the pixels in theimage are approximately the same in brightness levels with the exceptionof the location where a LED was turned on or off where there is expectedto be a large difference in brightness for a small number of pixels.This located the LED in the image. For any one image we have a number ofLEDs which we can use for calibration and later for operating the SPMV.

However, this system may provide an inherent feature that it isparticularly robust. It works in a large range of lighting conditionsand is very fast computationally. However, it might still be the casethat a lighting transition is falsely detected. For example, some otherelement in the scene might experience a brightness transition by someunlucky chance. Alternatively, the LED itself may be occluded (by beingon the other side of the SPMV for example) but it may shine on someother part of the scene which will be recorded as if it was the locationof the LED.

The solution depends on the fact that we know the relative positions ofthe LEDs (the distances and the angles between them). This means that ifyou have, say, three true LED locations and a false one, we can easilyfind the false one and remove it. If the camera is calibrated, this iseasy. The good ones will have valid distances between them (wherever theSPMV is in the room) and the bad one will have bad distances to theother three. However, even if the camera is not calibrated we can findthe “bad guy.” It can be shown that a configuration of a few LEDs thatinclude false readings will, in general have NO intrinsic or extrinsiccalibration possibility that would produce such a configuration of LEDpositions. This is because the configuration is constrained by theknowledge we have of the distances and angles between the real-worldLEDs. Once we know that the set as a whole is bad, we can choose subsetsof LED positions and see whether there is some calibration configurationfor the subset. If we find good subsets, we can easily remove those thatcan fit into no calibration configuration.

As will be discussed below, it may be possible, in some embodiments, toemploy ‘iterative techniques’ for computing one or more calibrationparameter(s).

Initial Intrinsic Parameter Calibration

In the current example, the first task is to determine the intrinsicparameters of each camera. An initial estimate of the camera intrinsicparameters may be obtained as part of the manufacture of the systemitself and not as part of the user-setup of a particular instance of thesystem. A simple articulation of the specification of the components issufficient for input to the further calibration.

The intrinsic parameters are expressed by the matrix A:

$\quad\begin{matrix}\alpha & \gamma & {u\; 0} \\0 & \beta & {v\; 0} \\0 & 0 & 1\end{matrix}$

Where:

α is the distance, in horizontal pixels, from the lens plane to thesensor plane (focal length if focused)β is the same distance in vertical pixelsγ is a measure of the skew of the imageu0 is the horizontal pixel coordinate of the image centerv0 is the vertical pixel coordinate of the image center

Increasing Intrinsic Parameter Precision

In some embodiments of the invention, the initial pre-setup estimate ofintrinsic parameters is used to calculate a more accurate set of valuesfor the specific instance of the system.

The method used involves keeping the SPMV steady while taking a numberof pictures from a single camera whose intrinsic parameters are to bedetermined until an image location has been measured for each LED on theSPMV. We refer to this as one data set. Next, the SPMV is instructed toturn (and perhaps move) and another data set is measured. This isrepeated a number of times ranging from 4 to perhaps 100. It should bestressed that no human-operator involvement is required for thisoperation. The fact of powering the system in a state where its ownrecords show that calibration has not happened yet is enough to initiatethe calibration. The user need only be asked not to interfere and someform of detection of user interference should he/she not cooperate isalso required for complete robustness.

The method calculates an optimal value for A such that the expectedimage locations of the LEDs are as close as possible to the actualpositions measured. The distance from the camera to the SPMV is notknown. Usually, it is not possible to determine both A and the distanceto the SPMV at the same time because we cannot know whether cameramagnification or distance from the object is the cause of a particularsize. The reason this is not a problem can be expressed as finding theImage of the Absolute Conic or it can more simply be explained as theeffect of perspective shortening. The shorter the distance to the objectthe stronger the perspective effect is. This need not be representedexplicitly, the iteration method used implicitly uses it to achieve thecorrect result.

It is possible to employ the Levenberg-Marquardt Iteration techniquewhich is well known to practitioners in the field; referred tohenceforth simply as ML iteration. A good implementation can be found in[Press 2009]. It will be used extensively. In each case we will provide:

1. A mathematical model of a relationship between at least two sets ofdata

2. The sets of data points

3. An initial guess at the parameters of the model

4. An error evaluation function

If the guess is close enough, the iteration will converge on a goodvalue for the parameters of the model.

Assume a coordinate system as in FIG. 2A. The point on the floor (orother surface on which the SPMV has been placed) beneath the back rightof the SPMV is arbitrarily considered the point of origin of the worldcoordinate system. All the locations of the LEDs on the SPMV arespecified within this given world coordinate system. We thus have eight(in some embodiments) known points in this coordinate space. Using theflash detection described above we know the location in the image ofeach of the LEDs. We thus have eight point correspondences.

Writing the homogenous world coordinate vector as X and the homogenousimage vector as x, we know that:

x=AR[I|−C]X  (eqn. 5.2.3.1)

where I is a 3×3 Identity matrix, R is the rotation matrix of the camerarelative to the chosen axis system and C is the location of the camerain that system. R can in this case be expressed as a single rotationabout a unit vector. For this we need two parameters for the x and ycomponent of the unit vector with the z coordinate implied by the unitmagnitude of the vector as well as a third parameter, θ, for therotation. C is three more parameters and A is expressed in terms of the5 parameters given above. We already have an initial estimate for thevalues in matrix A and we need to generate an initial estimate for theremaining six parameters.

The first step is to generate a number of sets of data. Each set of dataincludes the taking a camera image and locating each of the eight LEDsin that image using the flash detection. Next the camera and/or the SPMVis moved to a different position and orientation relative to the cameraand another data set is collected. For this set of data it is preferablethat the SPMV is fairly close to the camera in order that the effect ofperspective shortening on the further LEDs is more accentuated resultingin more accurate measurement and hence results.

We now have N sets of data each of which contain a number of world-imagecorrespondences. For each data set, the value of matrix A is identicalbut R and C are different. The ML iteration is therefore required toimprove the value of R and C individually for each data set andcollectively improve A for all the data sets combined.

We now need to provide an initial estimate for R and C for each dataset. This is done by first creating an estimate of the R and thencalculating C from this value. We generate a value of R by iteratingroughly through the space of possible values for R. A general 3Drotation matrix can be seen as a combination of three independentorthogonal rotations around each of the three axes. We simply divide thecomplete 2π rotation into 32 (or some such number) divisions. This gives32 possibilities for the x and y axes each and another 32 for the zaxis. This gives 32,768 possibilities. However, since the y axis isessentially the upwards direction, the camera system is on a roughlysmooth surface and the camera is installed essentially horizontally, wecan assume the z rotation is slight. 3 z rotations are sufficient forthe estimate and therefore the number of possibilities to check is thusonly ˜3000. A modern PC can perform the following calculation 3000 timesin much less than a second typically.

For every possible value of R there is one value of C that is theclosest to making a good match between world and image coordinates. Wecalculate this value for C and attach a score to this value of R as asum of the square of the distance between the calculated image pointsand the measured image points. The value of R with the lowest score winsand becomes the input value to the ML iteration.

The following is the details of the calculation of C for a given valueof R.

We write the world coordinate for any given world point, assuming a unitmatrix for the intrinsic parameter matrix A, as W. It is simplycalculated as:

W=A·X  (eqn. 5.2.3.2)

Writing R·[I|−C] as [R|t], we have:

x=[R|t]·W  (eqn. 5.2.3.3)

We write R as [R₀, R₁, R₂] (i.e. R₀ is the first row of R), x as [s·u,s·v, s] and t as [t_(x), t_(y), t_(z)]. We use the period (.) toindicate multiplication for scalars and dot-product for vectors.

A data set includes about six valid correspondences because two LEDs arenormally hidden from view. We write the value for the i^(th) data pointas X[i], for example.

Thus we get:

s·u=R ₀ ·W+t _(x)  (eqn. 5.2.3.4)

s·v=R ₁ ·W+t _(y)  (eqn. 5.2.3.5)

s=R ₂ ·W+t _(z)  (eqn. 5.2.3.6)

From these we get, using two data values; i,j:

t _(x)=((u[j]·(R ₀ ·W[i]·v[i]−R ₁ ·W[i]·u[i])−(u[i]·(R ₀ ·W[j]·v[j]−R ₁·W[j]·u[j])))/(u[i]·v[j]−u[j]·v[i])

t _(y)=((v[j]·(R ₀ ·W[i]·v[i]−R ₁ ·W[i]·u[i])−(v[i]·(R ₀ ·W[j]·v[j]−R ₁·W[j]·u[j])))/(u[i]·v[j]−u[j]·v[i])

t _(z)=((R ₀ ·W[i]+t _(x))/u[i])−(R ₂ ·W[i])  (eqns. 5.2.3.7)

Different results are obtained for every pair of values chosen from thedata set, so a few pairs are chosen (1&7, 2&6, 3&5) and the values areaveraged. Once a value is obtained for t, the score is calculated byapplying [R|t] to every value in the data set obtaining a set of imagepoints that would be where the LEDs would be imaged if the chosen valueof R was the correct one. Distances are measured from the calculatedvalues to the real value and the sum of the squares of these distancesis the score given to R.

We iterate through the ˜3000 values of R and find the R with the lowestscore. This value along with the calculated value for the camera centerC becomes the estimate that is input into the ML iteration for that dataset.

Next we perform ML iteration on this one data set in order to improvethe values for R and C. A, the intrinsic parameters of the camera isstill held constant. The model for ML used is as follows:

P=A[R|t]  (eqn. 5.2.3.8)

such that P is the camera matrix. We apply P to each of the worldcoordinates of the LEDs and thus determine the calculated image points.The error function is the sum of the squares of the pixel distancesbetween these and the actual image locations of the LEDs. Thus we get inimproved value for R and t (and hence C) for the data set. This is thevalue that is used for the next stage.

Next, we combine a number (for example, between 4 and 100) of data sets.Each data set already has an optimal value of R and C of its own.However, they all share a value for A. We now input all the data setsinto an ML iteration where the model is exactly the same as the lastone. The model is eqn. 5.2.3.8 and the error function is the sum of thesquares of the distances between points calculated using PX and themeasured locations as before. The only differences are that, we now havemultiple data sets each with their own R and C and that all theparameters A, R and C are allowed to change. The only restriction isthat while R and C are applied only to the values of their own datasets, all the data sets must have the same A.

As a result we now have an optimal value of A. The same procedure can beapplied to each of the cameras since their intrinsic parameters may bedifferent.

In some embodiments, the data sets should be measured with widelydiffering orientation of the SPMV. The plane (more or less) formed bythe top of the SPMV does not change, which is a problem. However, theplane (more or less) formed by the front, back and sides changesignificantly thus ensuring a robust value for A.

The model we just described will be referred to as the fixed cameracenter camera matrix model. The process of calculating a seed value forthis model will be referred to as the fixed camera center seeddetermination process and the process for calculating A from this modelwill be referred to as the Iterative ML fixed camera center process forcalibration of camera intrinsic parameters.

We now have a value for A. This need not be determined too often. Itshould be performed on the initial setup and then infrequently. If thelens on the camera can be adjusted manually, this will change the valueof A. Such a change should be discouraged and if it is done, the systemshould be “informed” in order to do the calculation again.

Extrinsic Parameters Calibration and Pan-and-Tilt System Calibration(See, for Example, FIG. 22B)

Next we seek to determine the calibration, position and orientation ofthe camera-system in some world coordinate system. Our goal is todevelop a model for the extrinsic (R and C) parameters of the cameras aswell as the parameters of the servos that pan and tilt the camera. Weneed to know all the fixed parameters of the model and theirrelationship to command parameters from the controlling computer.

Again we start with the coordinate system as in FIG. 2A relative to theSPMV. Referring to FIG. 23, we need to determine:

-   -   1. The center of rotation of servo 4 in world coordinates (O).        This is essentially a measure of where the user placed the        camera system.    -   2. The distance from O to the camera center C, (L). The camera        is assumed to be on the axis orthogonal to the axis of rotation.        (Thus if servo 4 is not tilted at all the camera is in the        center of rotation of servo 3.    -   3. The angle rotated by servo 3 for every unit of rotation as        transmitted by the controlling computer (k_(h)). The controlling        computer sends some arbitrarily scaled number to the        microcontroller controlling the servo. The latter translates        this into some pulse width which is the controlling mechanism        for the position of a servo. The unit of rotation used by the        controlling computer is referred to as i_(h).    -   4. The angle of the camera relative to the chosen world        coordinate system when i_(h) is zero for horizontal servo 3        (θ₀). This is a measure of the orientation of the camera as        placed on the surface by the user.    -   5. The angle rotated by servo 4 for every unit of rotation as        transmitted by the controlling computer (k_(v)). This is a        similar to k_(h). It will have a similar value but each servo        may be manufactured differently.    -   6. The angle of the camera relative to the chosen world        coordinate system when i_(v) is zero for vertical servo 4 (φ₀).        This is a measure of the orientation of the camera as a function        of the position of the midpoint of the servo within the        pan-and-tilt system.    -   7. The angle of the camera as rotated about the z direction.        This is the same as the rotation about the z axis when the        horizontal and vertical rotations are such that the principle        axis is the z direction (ω₀). This is not controlled by the        controlling computer and there is no z axis rotation in the        pan-and-tilt system. However, the camera may not have been        installed absolutely flat and the surface that the camera is on        may not be horizontal. This is therefore an important, if minor,        correction in the system.        We now develop the model. Assume a coordinate axis system such        that the axis of rotation of the horizontal servo (3) is roughly        the direction of the y axis. We define θ as the angle that the        camera has turned horizontally or specifically that the camera's        principle axis makes with the z axis of the world coordinate        system in the x-z plane. φ is the angle that the camera has        turned vertically or specifically the angle that the y axis in        the camera's coordinate system makes with the y axis direction        of the world coordinate system. From the definitions above we        can write:

θ=k _(h) i _(h)+θ₀  (eqn. 5.2.4.1)

φ=k _(v) i _(v)+φ₀  (eqn. 5.2.4.2)

We write O as [O_(x), O_(y), O_(z)] and C, the camera center as [C_(x),C_(y), C_(z)]

C _(y) =L cos(φ)+O _(y)  (eqn. 5.2.4.3)

C _(x) =L sin(φ)sin(θ)+O _(x)  (eqn. 5.2.4.4)

C _(z) =L sin(φ)cos(θ)+O _(z)  (eqn. 5.2.4.5)

The extrinsic camera matrix requires a rotation matrix. The model asdescribed so far already specifies the camera center, C. We also havethree rotation angles, but they are not orthogonal so a slightlydifferent approach must be used to calculating R.The vertical servo which rotates the camera about the x axis can betreated as a standard matrix of the form of a Givens Matrix which we'llcall Qx:

$\quad\begin{matrix}\begin{matrix}1 & 0 & 0 \\0 & {\cos (\varphi)} & {- {\sin (\varphi)}} \\0 & {\sin (\varphi)} & {\cos (\varphi)}\end{matrix} & \left( {{{eqn}.\mspace{14mu} 5.2}{.4}{.6}} \right)\end{matrix}$

Thinking simply, the matrix for horizontal rotation can also be a Givensmatrix of the form:

$\quad\begin{matrix}\begin{matrix}{\cos \; (\theta)} & 0 & {{- \sin}\; (\theta)} \\0 & 1 & 0 \\{\sin (\theta)} & 0 & {\cos (\theta)}\end{matrix} & \left( {{{eqn}.\mspace{14mu} 5.2}{.4}{.7}} \right)\end{matrix}$

If we calculate the horizontal rotation first, the axis of verticalrotation physically moves with the camera. However, in the newcoordinate system (calculated after the horizontal rotation alone) theaxis of vertical rotation is actually still the x axis of the newsystem. Therefore by calculating the vertical rotation second, a Givensmatrix can be used too.We now consider performing the same calculation with vertical axisfirst. We do this in order to introduce a method for calculating anerror due to the fact that the camera may not be situated exactlyhorizontally but may be skewed a little as represented by a smallrotation about its own z axis.We first calculate the vertical rotation using the vertical Givensmatrix above (eqn. 5.2.4.7). However, now the horizontal rotation aboutthe y axis cannot take the simple form of eqn. 5.2.4.6 because in thenew coordinate system the world y axis about which the horizontal servorotates has been rotated too and is now in a new position in the y-zplane. So instead we use the form for a rotation about a unit vector. Weuse the following routine (defined in C) to generate a rotation matrixexpressing a rotation of theta about a unit vector [x,y,z]:

void  MakeAxisRot(Mat_O_DP &  R, DP  x, DP  y, DP  z, DP  theta){DP  c = cos (theta); DP  s = sin (theta); DP  C = 1 − c; DP  xs = x * s; DP  ys = y * s; DP  zs = z * s; DP  xC = x * C; DP  yC = y * C; DP  zC = z * C; DP  xyC = x * yC; DP  yzC = y * zC; DP  zxC = z * xC;   R[0][0] = x * xC + c; R[0][1] = xyC − zs; R[0][2] = zxC + ys;   R[1][0] = xyC + zs; R[1][1] = y * yC + c; R[1][2] = yzC − xs;   R[2][0] = zxC − ys; R[2][1] = yzC + xs; R[2][2] = z * zC + c;}  ..

where DP is a double precision typedef. Mat_DP is a typedef that definesa two-dimensional matrix.We start off with the y axis vector [0, 1, 0] and apply Qx (eqn.5.2.4.7) to that thus generating y′, the axis for the nownot-so-horizontal rotation. We then use the above method with the unitaxis y′ to generate the second rotation matrix. This method givesidentical results to the first method, the difference between the twobeing simply that the order of matrices has been reversed and thereforein the second method the effect of the first on the second's axis ofrotation must be accounted for.The z axis rotation can be accounted for similarly. Assume that thecamera is rotated a fixed angle about its own z axis, ω. If we calculatethe z rotation first, the axes of vertical and horizontal rotations willnow have to be modified by the z rotation. We can thus use either orderof calculating the next two rotations. If we do the vertical first, thex axis is first modified by the z rotation to create a new unit axis x′and then the unit-vector routine given above can be used to generate the“vertical” rotation. Next, the combined rotation matrices can be appliedto the y axis to generate y″ and the unit-vector routine used yet againto supply the third matrix.Since the model can now calculate R and C, together with A, we now havea complete model of the camera imaging system including a camera matrix(the basic conversion of world coordinates to image coordinates as givenby eqn. 5.2.3.1) in terms of α, γ, u0, β, v0, θ k_(h), i_(h), θ₀, φ,k_(v), i_(v), φ₀, O, C, L and ω.These parameters change at different times. Assuming that the lenscannot be adjusted, that the length of the arm of the vertical servo isnot significantly temperature dependent, that the seating of the cameraon the system is not adjusted and that the servos do not start to wearout, α, γ, u0, β, v0, k_(h), k_(v), L and ω will stay the same all thetime. It might be good to calibrate them every now and then but we canrefer to these as fixed for a particular instance of the system. Thus aninitial calibration is required to ascertain these values and then theycan be left unchanged. (The only reason to change these later on is ifour system is continuously providing readings which might improve theaccuracy of these values.) We refer to this set as the system-constantmodel values.Whenever the camera system as a whole, including the base, is moved orturned θ₀, φ₀ and O will change. Thus whenever we determine that thecamera base has moved, these values should be recalculated. These can befigured out so quickly that it makes sense to do this often,particularly at start-up or perhaps at the start of each new assignment.We refer to these as the position-constant model values.

i_(h) and i_(v), are under direct control of the software running on thecontrolling computer and consequently C, θ, and φ change whenever theydo. This is the basic action of moving the servos and thereforeredirecting the cameras. We refer to these as the controlled modelvalues. The purpose of creating this model has been to determine thevalues of all the other parameters in the model and therefore togenerate the controlled models values and subsequently the Camera Matrix(P=AR[I|−C]). If we know all the parameters of the model then every timethe controlling computer sends a new servo position instruction we cancalculate the complete Camera Matrix including both extrinsic andintrinsic parameters.

The model we just described will be referred to as the pan-and-tiltcamera matrix model.We use this model in three phases:

-   -   1. Initial calibration of system-constant model values    -   2. Subsequent calibration of position-constant model values    -   3. Determination of controlled models values every time the        computer changes i_(h) and i_(v), the parameters that control        the servos.        For the first phase of initial calibration of system-constant        model values we can either accept the system-constant model        values as given by the manufacturing process or we can use these        given values as inputs to seed an ML iteration and thus improve        the values. We also have a number of options as to how to go        about improving the values. For all options, the initial        procedure is the same:    -   1. Point the camera at the SPMV 120. (This is easily done by        starting the LEDs flashing and moving the camera until the        flashing comes into view then centering on the flashing and        perhaps determining the boundaries of servo pan and tilt wherein        the SPMV LEDs are fully in view.    -   2. Set the LEDs flashing in order to capture one data set        including one set of correspondences between world coordinates        of the LEDs and the location of their corresponding images in        terms of pixel coordinates in the image. (The origin of the        world coordinate system is arbitrarily set for the whole process        as the point on the floor below the back right corner of the        SPMV).    -   3. Record the values of i_(h) and i_(v) for which the data set        was collected.    -   4. Move the camera to another location such that the SPMV is        still fully in view and repeat steps 2. and 3.    -   5. Collect all the data sets and corresponding servo command        parameters and provide them as data for an ML iterative process.        The ML process implements the pan-and-tilt camera matrix model        as its basic processing model and the error function it uses is        the sum of the squares of the distances between the images        locations as calculated by the model and the actually measured        values.    -   6. Seed the initial values α, γ, u0, β, v0, θ k_(h), i_(h), θ₀,        φ, k_(v), i_(v), φ₀, O, C, L and ω using one of the processes        described below. However, even if we know values for the        system-constant model values, we need a way to provide initial        seed values for the position-constant model values. This can be        achieved by inputting the first data set collected in step 2 and        using these as input for a fixed camera center seed        determination process. This gives us a value for θ, φ and C. For        the seed value we set O as being L below C. We then calculate θ₀        and φ₀ using manufacturing values for k_(h) and k_(v) and using        the equations for θ and φ given above. We now have all the        constant values we need as seeds from the model from the first        data sets. For the first as well as all the data sets we now use        the values of i_(h) and i_(v) from step 3 and the seed values of        all the other model values to generate seed values of θ and φ.        In order to seed the model we can use one of the following        options:    -   We can use the Iterative ML fixed camera center process for        calibration of camera intrinsic parameters to calculate α, γ,        u0, β, v0. We then hold these values constant (the ML        implementation we use allows us to choose which parameters of        the model are to be held constant and which to iteratively        improve) and the rest are left free to change.    -   We can accept some of the manufacturing values such as k_(h) and        k_(v). In other words, we will let these parameters stay fixed        during the iteration. These actually can be used to determine a        value of α and β without requiring an image that has a lot of        perspective shortening. This is because if the angle rotated is        known, and the world coordinates are known as well as the change        in image locations as result of that rotation, this determines        the focal length of the camera. To do this α and β must not be        held fixed during iteration. We need not provide an analytic        equation for this relationship, it is sufficient that there is a        defining relationship with effects clearly outside measurement        error for the ML iteration to assign correct values to the        model. This represents a new mechanism for calibration of        intrinsic parameters of the camera.    -   We can set no parameters to be fixed but use all previous values        and manufacturing values as seed values that can change in each        iteration. In theory this mechanism can work because the        perspective shortening defines the values of internal        parameters. However, in practice, this method will only produce        acceptable results where the SPMV is fairly close to the camera.

Calibrating SPMV Motor Movement (See for Example, FIG. 23)

The SPMV is moved by motors, some of which may contain internal feedbackmechanisms which allow them to be set to turn to a specific angle. Suchmotors may have speed and power controls. The motors will, in general,turn the SPMV or one of its components, or move the SPMV or one of itscomponents. The motors will take some form of input ranging from turnoff and on, analog or digital signal input levels, period or frequencyin the input signal, duration of input or some such variation thatdetermines the speed, power, angle or some other output parameter.

In general, particularly for cheaper components, the mapping from inputparameter to output parameter is not exact. Firstly, each instance ofthe motor might have a different mapping. Secondly, over time themapping may change. Motors may wear down or battery charge levels maychange resulting in different motors performance. Thirdly, the mappingmay depend on such simple differences as the material of the floor orwork surface. The SPMV may move much more slowly on carpet as on marble.

For these reasons it is important to create calibration for the mappingof motor inputs on the SPMV to motor outputs. This is done by providinga range of inputs to the motors and for each input monitoring the motorresponse. A simple example may be sending an “on” signal for a varietyof durations and in each case determining the resultant change in theposition of the SPMV. The positions of the SPMV before and after thecommand can easily be determined using all the techniques of locationdetermination using LEDs described here. The result of thesemeasurements is a mapping between a set of inputs and a set of outputs.These can be put into a table and used by “looking up” the desiredresult and finding the closest appropriate input. Alternately, amathematical model can be built using standard numeric techniques suchthat a simple linear or non-linear function relating input to output isdescribed and the constants of that function are determined by theobservations.

Determining Pan-and-Tilt State

While using servo positions to both calibrate a system and to providetriangulation information, a problem arises. A servo is controlled bythe pulse width of the signal sent to it by its controller. The value ofi (i_(h) and i_(v)) in the previous discussion ultimately translates toa specific period for which the signal is high out of a repetitionperiod of approximately 2 ms. However, servos are built with a deadbandwhich is a range of values within which the pulse width may changewithout causing any change in position in the servo. The reason for thisis to prevent “jittering” as the servo responds to minor noise in thecontrolling signal.

This may present a problem for our mechanism because it means that theservo position is not an exactly repetitive result of the input i. Inpractice, if multiple images are taken with the same input value i, eachimage may differ from the others by a small number of pixels. In onespecific configuration this was up to 4 pixels at most. However, higherresolution cameras will mean that this number may be larger. The marketfor servos includes both “analog” servos with a large deadband and“digital” servos for which the deadband can be controlled. Therefore,for more expensive implementation of this invention this error can bereduced. However, in such cases the microcontroller must guarantee avery exact pulse width requiring fast, dedicated microcontrollers.

We now present a method for handling this servo inaccuracy. This can beapplied for the calibration phases as well as for later SPMV guidancephases as will be explained below.

We refer to the input value for the servo position as i. However, we candeal with the deadband issue as if the servo actually received asomewhat different value of i, i_(a). This is the exact value the servoactually uses to set its position. If a small change is made in thevalue of i and the change is within the deadband region and the servodoes not move at all we can say that i_(a) has not changed at all. As wecontinue to increase i, eventually the servo will move a significantamount that is not proportional to the last change in i. We can now saythat the value of i_(a) has “jumped” to a new value proportional to theactual move in the servo. In calibration phases as well as the laterSPMV guidance phases we must use the value i_(a) instead of i in ourcalculations.

When a change is made in i_(a), a rotation is effected and the imagechanges by a specific number of pixels approximately proportional to thechange in i_(a). The number of pixels moved can be counted in principlethus giving a way of figuring out i_(a). In practice, except for verysmall changes in i_(a) close to the principle axis of the camera thisrelationship is not linear. It is normally a rotation in the imagecoordinates x and y and it “stretches” as it moves further from theprinciple axis. We must account for this non-linearity.The first method applies to the calibration phase. During thecalibration phase this can be accounted for simply by allowing the givenvalue of i_(h) and i_(v) attached to each data set to change with the MLiterations. This is unusual because these values were data values tillnow and not model values. Therefore, they must be copied to the modelvalues before the iteration phase. However, a restriction must beapplied. The average values of all values of i thus modified must remainthe same. Otherwise, the ML engine could simply change i arbitrarily inorder to minimize the error function. By making this change in the MLmodel, we can account for the deadband effect during calibration.A second method for correcting for deadband is during regular cameraoperation. Later, when the system-constant model values and theposition-constant model values have been determined, whenever the camerais moved, instead of applying the new value of i, we can test thechange. We use our model to recalculate what we expect the new image tolook like. If we had the exact value of i_(a) we would be correct exceptfor the part of the image that has just moved into view. For thepurposes of this calculation we ignore the part of the image that hasjust come onto view and focus on the remainder: the part of the imagethat is identical in both images but has been rotated due to the cameramovement.Starting with i as the first guess for i_(a), we calculate the 3×3Homography matrix, H, that would convert the first image into what thecamera would see if it was rotated by a servo with input i_(a) and callthis the calculated image. We know from our calibration how to calculateR, the rotation matrix that the change in i_(a) applies to the servo. His given by

H=ARA ⁻¹

(relevant for step S527 of FIG. 30A and for FIG. 30B)Where A is the intrinsic camera matrix we have been using all along.Actually this is true only where the rotation is about the cameracenter. In reality the center of rotation is not about the camera centerbut for small movements of the center relative to the distance from thepoints of interest this is often good enough. If it is not good enough,a more accurate equation for H can be used which relies on the fact thatmost of the points in the image are on a known plane. In our case, thatis the plane of the floor or work surface which we have defines as theplane y=0. The general equation for H, where the center of rotation isnot the center of the camera is given by a definition of the plane in acoordinate axis of one of the cameras (R must also be converted to thatcoordinate frame) as π=(n^(T), d)^(T) as

H=A(R−tn ^(T) /d)A ⁻¹

(relevant for step S527 of FIG. 30A and for FIG. 30B)Once we have expected or calculated image and the actual image afterrotation we perform a Gaussian convolution causing a slight blurring onboth followed by a Sum of Absolute Difference (SAD) between the pixelsof the calculated image and the actual image. If the result of the SADis close to zero we can conclude that indeed ia=i. However, if it isnot, we iterate through minor changes in i_(a) in both directions. Foreach iteration we calculate H, generate the expected image, blur it andperform the SAD. We then select the iteration with the lowest sum to bethe actual value for i_(a).This mechanism produces a very good value of i_(a) but it assumesnothing in the actual scene has changed; only the camera has moved. Ifthe camera is tracking a moving SPMV, this may not be the case. Thereare a number of potential responses to this issue.

-   -   1. One response is that areas of the scene that have really        changed will show a bad match for all the test values of i. In        that case those pixels do not bias the overall result away from        the correct value of i.    -   2. Another response is that during SPMV guidance, when the SPMV        is in the middle of moving, accuracy is not so critical—a few        pixels may be acceptable. Once motion has stopped accuracy is        more important.    -   3. Perhaps the best solution is to take more than one (two        should be sufficient) images for each camera move. The two        images will have identical i_(a) and therefore the only        difference between the two will be due to motion. The pixels        involved in the motion should then be excluded from the SAD.

Single-Camera Determination of SPMV Position

Once calibration of system-constant model values and position-constantmodel values has been completed, the instance is ready to guide a SPMV.Movement commands are sent to the SPMV and, in transit, an LED data setis recorded. This can now easily be used to calculate the position ofthe SPMV. Since the camera matrix, P, is known we can write for eachLED:

x=PX  (eqn. 5.4.1.1)

where x is the homogenous vector of the image of the LED and X thehomogenous vector of the world coordinate of LED. We define thepseudo-inverse of the camera matrix, P⁺ as

P ⁺ =P ^(T)(PP ^(T))⁻¹  (eqn. 5.4.1.2)

The theory and calculation of pseudo-inverse is well-known in the field.Define a vector V that joins the center of the camera, C to the pointP⁺x. Thus:

V=C−P ⁺ x  (eqn. 5.4.1.3)

We define a line of points in world space as:

Pt=P ⁺ x+kV  (eqn. 5.4.1.4)

where λ is an arbitrary constant. We know that any point Pt will beimaged at the point x.We can expand eqn. 5.4.1.4 into its scalar components:

Pt _(x) =P ⁺ x _(x) +λV _(x)

Pt _(y) =P ⁺ x _(y) +λV _(y)

Pt _(z) =P ⁺ x _(z) +λV _(z)

However, since we assume that the SPMV is still on the same surface asthat we defined as y=0, we know the Pt_(y) coordinate of the LED sincewherever the SPMV moves (assuming it is either wheeled or can move itslegs into a “rest” position) the Pt_(y) coordinate of the LED willremain the same. If we know the Pt_(y) coordinate of Pt and we know theother elements of eqn. 5.4.1.4, we can easily calculate λ. Once we knowλ, we can use eqn. 5.4.1.4 to calculate the Pt_(x) and Pt_(z)coordinates of the LED. In theory, two LEDs are sufficient to give theposition and orientation of a simple wheeled SPMV since the full worldcoordinates for any one LED can be calculated fully and independentlyusing this method. Collecting a full data set allows Least Squaresmethod to be used to increase the accuracy. However, if speed isimportant to generate real-time guidance information, only two LEDlocations need be measured. Speed is necessary if the method is beingused to correct the SPMV that has veered slightly off course andaccurate arrival is important. Guidance may also be necessary if forreason of cost the mobility mechanism of the SPMV is very inaccurate.

This method calculates L using the known Pt_(y) value and then generatesPt_(x) and Pt_(z) values. However, this works well for a wheeled vehicleor some other SPMV whose motion type is such that we can know the heightof the LED above the floor. For other SPMV kinds, such as those that uselegs and therefore the Pt_(y) coordinate is not known, the location canstill be calculated quickly. All that is necessary is to determine moreLED pixel locations. We thus have more than one instance of eqn.5.4.1.4. with different values of λ: λ₁, λ₂ . . . . Since we know therelative distances and orientation between the points, we can providethese as constraints on eqn. 5.4.1.4 and thus trivial algebra willprovide the real-world location of the LEDs. This method is almost asfast as the method using known height above the floor (work surface) andis still easily fast enough for real-time determination of real-worldlocation using a single camera.

The entire guidance calculation can be performed in well below 1/10^(th)of a second with standard cheap cameras and a low-end controller at thecamera. This makes this method extremely significant for real-timeinteraction. The down side of this method is that it applies only to theSPMV or an object outfitted with LEDs at accurately known location. Aswill be explained later, this method that provides very high speed atlow cost can be combined with other methods in order to interacteffectively with the environment. This combination is a key teaching ofthis invention.When the SPMV approaches the edge of the camera image, the camera mustmove in the general direction where the SPMV is about to exit the image.At this point i, the input signal to the camera servos will change andthe camera model may be used to calculate a new camera matrix. Dependingon the constraints of the task, image matching may be used to increasethe accuracy of i_(a) as described earlier.We have thus far described the single-camera calibration of the cameraand servo mechanism as well as the mechanism for fast location andguidance of a SPMV. We now start the discussion of two-camera systemthat can provide both an internal and an external representation of the3D geometry of the whole system. This latter mechanism must beintegrated with the former single camera mechanism in order to achievebest results.A Brief Discussion of LEDs on Objects Other than SPMVsLEDs as described here provide a powerful mechanism for real-timedetection of position. It should be noted that this method can also beused to speed detection of other objects besides an SPMV. For example,the goal posts of a game could have LEDs in them to facilitate exactlocation. In another example, a LED could be embedded in a ball used forSoccer. The significance of this second example is that the object maybe moving fast and requires very fast response time.

Stereo System Scene Discovery

In some embodiments, a plurality of camera are used (see FIGS. 1, 3A-3B,4B-4C). Although not a requirement, use of multiple cameras may beuseful for techniques related to stereo scene discovery.

The literature contains a vast amount of methodology regarding scenereconstruction using a stereo rig of cameras. There is no pointrepeating it here. This document will focus on the implementationdetails that are specific to this invention. These are as follows:

-   -   1. Typical stereo rigs (by no means all) have the two cameras        non-moving, or they are fixed on the same moving platform.        Additionally they are normally horizontally aligned. Finally, on        a fixed moving platform it is impractical to position them more        than 5-10 cm away from each other. This severely limits the        accuracy of triangulation when working at distances of over a        meter. In the case described here the two cameras are at an        arbitrary distance from each other and the pan-and-tilt systems        are entirely independent. (While arbitrary, it is still        recommended that the angle they subtend on the object of        interest is not much more than 90°.    -   2. The stereo rig described here is designed to work in        cooperation with the fast, single camera system described        earlier. This means that the calibration and camera position may        be used to aid the stereo method to be described. It also means        that the results of the two systems must be integrated into a        single cooperating system.

Pointing Two Cameras at the Same Area

The first challenge presented by an independent pair of cameras is thatthey need to point to roughly the same area. For depth information to beextracted from the pair of images, the same scene components must appearin the same image.

One solution for this is to combine the images from multiple positionsof the same camera into one very large image and apply stereo matchingalgorithms to a pair of combined images. The method for combining imagesfor a panning or rotating camera is widely discussed in the literature.There are, however, further challenges that arise by using this method.

Here we describe a different solution to this problem. This solutiontakes advantage of the fact that the camera position and orientation isknown to a reasonable level of accuracy. Assume that most points ofinterest in the scene are on or close to the floor (or the workingsurface) which defines the y=0 plane. Both cameras can point theirprinciple axis onto the same point on this plane. Clearly some pointswill appear in one image and not in the other, but around the center ofthe image, many points will appear in both. Once other planes aredetected as described above, the same method may be applied using thewalls of the room as reference planes.

Epipolar Matching

The next challenge is that the two cameras will not be, in general,aligned horizontally. Many stereo matching algorithms described in theliterature assume that the camera centers of the two cameras can bedescribed as a horizontal translation in terms of the images, with norotation. In this mechanism, the matching epilines, the lines on whichimage correspondences will occur, are simply the horizontal lines of theimage of the same image y coordinate. In our case, we need to extractthe matching epilines from our knowledge of the camera positions andorientation. This will now be described.

All the epilines meet at the epipole. The epipole for first camera isthe image of the second camera center in the first image. Since we knowthe camera matrix of the first camera and the world coordinates of thesecond camera center we can calculate the epipole for the first image.

We now generate epilines radiating from the epipole in 360°. The numberof such lines depends on the resolution we want to work at and theprocessing power available. Next we find which lines will cross theactual image. For example, a typical image may have pixel coordinatesfrom 0 to 320 horizontally and 0 to 240 vertically. A typical epipolemay be at coordinate −1500, 150 which is way off on the left and sidebeyond the actual image. We calculate which of the epilines cross intothe actual image and discard those that do not cross two of the imageborders. We are now left with a set of potential epilines from the firstimage.

We write the camera matrices as P₁ and P₂ for the first and secondcameras respectively, and similarly C₁ and C₂ for the two cameracenters, e₁ and e₂ for the two epipoles, I₁ and I₂ for specific matchingepilines. We write F, the fundamental matrix (actually the essentialmatrix since the cameras are calibrated) as:

F=e ₂ ^(skew) ·P ₂ ·P ₁ ⁺  (eqn. 5.5.2.1)

where e^(skew) is the skew matrix formed from the 3-vector e.

As described in standard stereo matching literature, if an epiline isdefined by a vector I₁ written as [a,b,c] where ax+by+c=0 is theequation of the line for the epiline, the matching epiline is calculatedas:

I ₂ =F·e ₁ ^(skew) ·I ₁  (eqn. 5.5.2.2)

For all the epilines in the first image that cross the boundaries of thefirst image, not all matching epilines in the second image cross theboundaries of the second image. In that case both the epilines that donot intersect the second image and the corresponding epilines thatgenerated them must be discarded.

We now have a set of matching epilines from the two images. We cancreate two new images using them. We will call these epimatch images.The image is formed by creating a fixed interval of the radius from theepipole of each image depending on the resolution and accuracy we wantto use for the stereo matching. All the points on the epiline generatedusing this interval that fall inside the image are used to generate theepimatch image. If we are using a gray-scale image we can, for example,generate the epimatch image pixel by performing a simple bilinearfiltering on the four nearest neighbor pixels of the original image.(The generated point on the epiline does not, in general, have integerx-y coordinates.)

The two epimatch images are now of the form used in standard stereomatching literature where each horizontal line of the first image is acorresponding epiline of the equivalent horizontal line of the secondimage. Standard techniques for matching the features of the two epilinescan be used and need not be discussed here. We will however, discusssome fast techniques that take advantage of the integration of thestereo-based information with the single-camera knowledge that we havealready gained.

It is important to note that the two epimatch images that have beengenerated should still retain the original coordinates of the imagesfrom which they were generated. This can be achieved simply using aparallel data structure. Once we know which pixel on one epiline matchesthe pixel of the other epiline, we will use the original coordinates inorder to produce the triangulation that gives us the world coordinatesof the scene point that generated the two corresponding image points.

It is possible to improve the fundamental matrix F using ML iteration atthis stage. If we do not assume that a match must occur only on theactual matching epilines but allow a leeway for finding matches, say onup to 4 nearby epilines we can find and record corresponding pointsusing this relaxed assumption. Any technique may be used to find thisnew set of corresponding points. Great success was achieved using asimple box matching algorithm. We now have a data set of thousands ofpoint correspondences that should all obey the model:

x ₂ ·F·x ₁=0

If we now create a simple error expression using:

Error=|x ₂ ·F·x ₁ |/|F|

we have all we need for an ML iteration. We can allow the values thatcomprise F to change in the iteration in order to minimize the errorfunction.

However, this is not a good solution because we move away from theinformation we have already calculated regarding the position andorientation of the cameras. Our goal is not to change this informationbut just to get a value for F that maximizes our ability to find matchesalong the epilines. We therefore can perform the ML iteration and alsoinclude data sets from the LED matches or other world-imagecorrespondences that we know. Alternatively we can add to the errorfunction a term that penalizes moving F away from the parameters of thecamera matrices underlying it. Another solution is simply to form F′such that F′=HF where H is some homologous transformation 3×3 matrix. Wethen allow only H to vary in the ML iteration.

Stereo matching algorithms are notoriously slow. This is one reason thatwe require combining the fast single-camera process for determining thelocation of a moving SPMV as will be described later.Identifying Extrusions from a Surface

We now describe a fast method for extracting important scene informationfrom a stereo rig calibrated according to the methods taught here.

Assume all the points in the image are actually part of the floor (orwork surface) and thus at world coordinate y=0. Form the epimatch imagesas described. Next find the x and z world coordinates that wouldgenerate the image point if the world y coordinate was 0 using themethod described earlier for fast calculation of LED position in section5.4. Next create correspondences along the epilines ignoring gray-scaleor color discrepancies between “corresponding” points but simply usingthe x and z coordinates calculated for each point along the epiline.

Now perform a slight Gaussian blurring and calculate the SAD of the“corresponding” pixel and perhaps that of a 3×3 box around the pixel. Ifthe value of the SAD is low then we can conclude that the assumption forthis pixel was correct and indeed it is part of the floor. However, ifthe value of the SAD is high, then the assumption is incorrect. We takethe “image” of the SAD values and convolve with a larger Gaussian tocreate a bigger blur in order to accumulate the SAD values of neighbors.We can say that wherever we have a big area of high SAD values, there issome rising from the floor probably corresponding to an object placed onthe floor or an obstacle.

This method is fast and produces good results. Furthermore it is a goodmethod to use as a starting point for finding correspondences on theepilines. Normally the problem starts off as an O(n²) problem where n isthe number of points in the epiline because initially any point maymatch any other point. However, once most of the points have beendetermined to be floor points, there is only a need to focus on theremaining points and thus n is drastically reduced.

The method can also be applied to planes in the scene that are not partof the floor. Once other planes are detected (vertical ones are normallyexpected), the same method can be applied to find these. Thus the wallsof the room can also be quickly determined.

Identifying Movable Objects

We now describe another method for identifying objects within the scene.The SPMV can be guided to move up to a specific extrusion or some otherarea that has potential for being a separate object. The SPMV is thenguided to apply some force to the object. If the object is relativelyrigid and it moves, its movement will have a uniform rigid nature.Motion estimation applied to the images before and after the movementcan be analyzed for this kind of rigidity. All pixels participating inthe movement may be marked as being part of the object.

Internal Scene Representation

The stereo camera system can be used to generate a complete 3Drepresentation of the scene of interest. Once the multiple stages ofcalibration have completed, if the system is allowed some time, thecameras can start turning on their own accord and produce stereo imagesof the entire range of movement of their servos. The methods justdescribed as well as standard stereo scene reconstitution methods areapplied to these images. The results are all combined into one internalrepresentation of the entire room. This may take a long time. However,the result is very impressive. As will now be described, not only doesthe system now have a “knowledge” of the entire room and all itsnon-moving components, but now we can display to the user the room he isin using full 3D display technology. Over time this internalrepresentation can be updated if the “motion” that has been detected isdetermined to be non-transitory.

Having such an internal database of the 3D features of the room and theimages captured at different angles also speeds up processing of movingcomponents in the room. When new images are taken, they may be comparedto the initial database thus yielding immediately which area of thepicture has changed. Stereo recreation of the new object or motion canfocus on this area alone and thus reduce the O(n²) problem describedearlier.

3D Scene Visualization

Once we have an entire representation of the scene of interest, thisactually takes the form of what is known in the literature as a “pointcloud”. We have millions of points in the room whose 3D coordinates weknow. These are all on the surface that is present to the cameras(ignoring transparent objects). We now want to turn this point cloudinto a surface which may be partially planar and partially a verycomplex surface. The immediate use is for a visual representation.However, there are other uses including object recognition.

The method used to turn the point cloud into a surface is calledtessellation. Methods for tessellation are described extensively in theliterature and need not be expanded upon here. The only point specificto the methods described here is the starting point of tessellation.Tesselation works well when it starts with a 2D grid of points (each ofwhich has 3 world coordinates: x-y-z). The 2D grid coordinates may bearbitrary as long as they make tessellation easy. The 2D grid chosen isthe grid of pixels in the first epimatch image described above. Theepimatch image specifies whether a pixel has a corresponding pixel inthe other epimatch image and therefore that this pixel is a valid pointon the grid.We therefore have a 2D grid with some elements of the grid invalid andthe remaining elements representing a pair of corresponding image pointsand therefore a valid world coordinate from the pixel cloud. The firsttask of the tessellation is to create triangles that are formed frompoints of the grid as close to each other (on the grid) as possiblewhile avoiding the invalid elements.The basic algorithm for tessellation works with pairs of grid linesgenerating basically optimal triangles as it goes along the lines. Wetry to generate pairs of triangles each time, one bottom-left and theother top-right. The disturbing factor is that an invalid grid elementcannot generate the vertex of a triangle. In the simplest case we startwith four adjacent valid elements two along the top and two on thebottom which generate two simple triangles.In other cases, the there may be invalid elements on the bottom or topand the algorithm has to deal with these accordingly. We provide the Csource code for the implementation of a tessellation algorithm. The codeis commented sufficiently to understand the algorithm. The only detailthat one needs to know about the structures provided is that STesselElholds the data for each element in the tessel grid and that it includesa member bWCValid that has value true if the grid element has validworld coordinates associated with it and is thus valid for use as avertex in a triangle of the tessellation process.

/* Function: ProcessLinePair Purpose: Generate all the triangles thatare valid between two grid lines Parsameters: listTris: List oftriangles to generate as the result of tesselation. Each triangleconsists of three vertices. Each vertex consists of a pair ofcoordinates that are the horizontal and vertical coordinates of thepixel grid. teTStart: element of top tessel grid line to start withteBStart: element of bottom tessel grid line to start with The elementfollowing these can be accessed by adding integers to pointers actuallythe integer added is iB for the bottom line and iT for the top line w:width of line in tessel grid iGL: horizontal index of first grid elementto process on the top line iGT: vertical index of the top line */ voidProcessLinePair(CListTris& listTris, STesselEl * teTStart, STesselEl *teBStart, int w, int iGlL, int iGlT) { int iT=0; int iB=0; STesselEl *teT = teTStart; STesselEl * teB = teBStart; // find first vali elementalong top line while (!teT−>bWCValid) { iT++; if (iT == w) { return; }teT++; } // Loop along line as long as there are still some triangles toproduce while (1) { // When we return here in the loop we are “startingclean” // as opposed to closing up open triangles // Declare the twoobjects to hold the triangle // Tri1 is the bottom left (BL) triangleand Tri2 the top-riqht (TR) UTri Tri1, Tri2; // The top left validelement is the first vertex for both triangles Tri1.x[0] = iGlL + iT;Tri1.y[0] = iGlT; Tri1.n=1; Tri2.x[0] = iGlL + iT; Tri2.y[0] = iGlT;Tri2.n=1; // Search for the first valid element on the bottom line. Wesearch // for the rightmost valid element that is not right of the firstvertex. iB = iT; teB = teBStart + iB; bool bNoBelowLeft = false; while(!teB−>bWCValid) { iB−−; if (iB < 0) { bNoBelowLeft = true; break; }teB−−; } // if there is one, make it the second vertex of the BLtriangle if (!bNoBelowLeft) { Tri1.x[Tri1.n] = iGlL + iB; Tri1.y[Tri1.n]= iGlT − 1; Tri1.n++; } // The following loop will iterate we find avalid // element on the top row. // Each iteration moves both top andbottom element one to the right // It keeps going if we are skippingboth top and bottom or just // building trinangles from elements of thebottom line iB = iT; teB = teBStart + iB; bool bKeepGoing = true; while(bKeepGoing) { // returning here in this inner loop means that we arenot “starting clean” // but rather finishing off triangles that alreadyhave one or // two vertices defined. // we start by simply finding thenext two elements top and bottom iB++; iT++; teT++; teB++; // if we gotto the end of the line we need generate no more triangles if (iT==w) {// we're done return; } // the simple case is where the right side hasvalid top and bottom. // we close up either one or two triangles andstore them if (teT−>bWCValid && teB−>bWCValid) { // if the BL trianglealready had two points we generate it // otherwise this candidate isdiscarded because after this // we “start clean” if (Tri1.n==2) {Tri1.x[2] = iGlL + iB; Tri1.y[2] = iGlT − 1; Tri1.n = 3; // this is howwe store a new triangle by adding it to the listlistTris.push_back(Tri(Tri1)); } // there is always a TL triangle inthis case // the order here is important for backface culling Tri2.x[1]= iGlL + iB; Tri2.y[1] = iGlT − 1; Tri2.x[2] = iGlL + iT; Tri2.y[2] =iGlT; Tri2.n = 3; // stoe TL listTris.push_back(Tri(Tri2)); // get outof this loop and “start clean”. bKeepGoing = false; } // the second caseis one where we have no valid bottom element // in this case we willonly generate one triangle before // starting clean else if(teT−>bWCValid && !teB−>bWCValid) { // If we already have 2 points thisis an easy option, // we just need to close up BL // actually this isneithe BL or TL because there is only 1 if (Tri1.n == 2) { Tri1.x[2] =iGlL + iT; Tri1.y[2] = iGlT; Tri1.n = 3; listTris.push_back(Tri(Tri1));} else { // we need to find a partner at all costs // however we knowthat the next top will also not find // a vetex below left so we areallowed to do this bNoBelowLeft = false; while (!teB−>bWCValid) { iB++;if (iB == w) { bNoBelowLeft = true; break; } teB++; } // use of the namebNoBelowLeft is somewhat misleading // because we are actually sayingthat we found a vertex // below but to the right of the top vertex //anyway, if there is a valid element close up one triangle if(!bNoBelowLeft) { Tri2.x[1] = iGlL + iB; Tri2.y[1] = iGlT − 1; Tri2.x[2]= iGlL + iT; Tri2.y[2] = iGlT; Tri2.n = 3;listTris.push_back(Tri(Tri2)); } } // start clean. bKeepGoing = false; }// If we only have a valid bottom element we add a vertex and loop againelse if (!teT−>bWCValid && teB−>bWCValid) { Tri1.x[Tri1.n] = iGlL + iB;Tri1.y[Tri1.n] = iGlT − 1; Tri1.n++; // on the way if we have threevertices // we can store a BL triangle and then make its right // edgethe left edge of the next triangle if (Tri1.n == 3) {listTris.push_back(Tri(Tri1)); Tri1.x[1] = Tri1.x[2]; Tri1.y[1] =Tri1.y[2]; Tri1.n−−; } } // else implied - go round for another go // wesimply move the search for both top and bottom pair // one to the rightuntil at least one of the two is valid } } }

The method as described provides one way to produce a triangle mesh fromthe point cloud calculated in the previous sections. The triangle meshcan now be used with any standard 3D rendering engine such as DirectX orOpenGL in order to present to a user a 3D representation of the screen.Such engines provide the ability for the user to move a virtualview-camera around the scene and inspect it from different angles. Thisprovides a very intuitive and useful way to interact with the scene forboth programmers and users. It is possible to zoom in on an item ofinterest or inspect from a different angle.

A triangle mesh by itself does not provide all the information that the3D model can present. The way to create an impressive information-ladenimage is to apply the images from the camera as a texture for the mesh.This is easily done given the methods described so far. The point cloudthat was used in the tessellation process includes a 3D world coordinateassociated with the point but also the original pixel coordinates ofeach of the camera images used in the triangulation. These images can beapplied as textures with the texture coordinate associated with eachvertex in the mesh being the original pixel coordinates. There are twotextures whereas a simple texturing process requires but one. Someimplementations may choose to use only one of the textures. Otherimplementations may choose to apply both textures with an alpha value of0.5 applied to each. Advanced 3D graphics engine support such multipletexture application. Of course, with only two cameras, any scenecomponents hidden from either of the two images will not be displayed inthe internal representation or in the graphic display. This can beresolved by adding more cameras at different angles on the scene. Thus,some implementations will choose to utilize any number of cameras usingsimilar methods to those taught by this invention.

There are various methods for combining triangulation from more than twocameras. The literature includes mathematical treatments of n-camerasystems where n>2. Other implementations may choose to stay with the2-camera system as described. Each pair of camera triangulatescoordinates as described. There will therefore be some points that arecalculated multiple times with slightly different coordinates in eachcase (usually). In that case a simple weighting system can be used tointegrate the different results.

Incidentally, multiple camera systems can also be used to cover morecomplex scene geometries. For example a corridor with corners may berepresented using a number of cameras such that each part of thecorridor is covered by at least two cameras (where coverage includes theability to turn the pan-and-tilt system towards the point of interest).In that case the system as described can be used both to get betterall-round information as well as to allow camera hand-off as the area ofinterest is progressed along the corridor.

Smoothing Visualization Surfaces

The image produced by the 3D graphic engine using this method issatisfactory but much image detail is lost. The reason for this is thatsince the triangles are small and the surface has a large degree offluctuation (due to calculation and observation error factors) relativeto the size of the triangle, the normals of the triangles vary quitestrongly. This causes the texture of the individual triangles to beviewed at angles that distort the detail of the overall texture.

There are a number of solutions which will be now presented to thisissue that provide rather excellent results:

-   -   1. For surfaces that are more or less planar or locally planar,        a simple algorithm such as least-square distance can be used to        calculate the equation of that plane. The world coordinates are        then calculated with the restriction that the point lies on the        plane. For this the algorithm described in section 5.4 for the        intersection of the vector from the camera center to image point        and the plane performs well.    -   2. Another solution is to perform a 3-dimensional convolution        with a Gaussian on all points on the tessel-grid. This creates a        blurring in the 3D domain which produces a good image for many        surfaces.    -   3. A third solution is to perform the following steps:        -   a. For each element in the 2D tessel-grid, find the normal            of all triangles adjacent to the element and perform an            average of these to calculate a normal for the element            itself.        -   b. Perform a 2D Gaussian convolution on the tessel-grid but            apply it to the normal of the grid element. This has the            effect of blurring the direction of the normal or, in other            worlds, making the differences between neighbors less            strong.        -   c. Calculate the distance neighbors on the grid are in front            of or behind the normal of any specific element.        -   d. Average over these values and move the element such that            its location along this normal is equal to the average.

Using any of these methods produces an excellent image with most of thescene showing at the resolution of the original image.

Method 1 above, however, will be used in any case to analyze thesignificant planes in the scene. Any areas of the mesh that aresignificantly different from the nearby plane are considered as anobject in their own right for the purposes of the internalrepresentation.Interacting with the Visualization

When a user clicks on any point in the 3D graphic representation of thescene, advanced engines are capable of providing the nearest vertex tothe 3D representation of the location of the mouse click. This featuremay be used to allow the user to interact with the scene details. Theclick is used to make a selection which may be interpreted as follows:

-   -   It may be interpreted as an object selected. In this case the        object could either be identified as such due to a significant        divergence from the plane as just described in sections 5.5.3        and 5.5.4.    -   It may be interpreted as a single point location in terms of a        specific 3D world coordinate.        This selection can either be used:    -   To create a label. In this case the user either creates a new        label or is asked to select from a list of labels that the        specific application has defined. In this way a user simply and        intuitively can input the mapping of the application to the        instance that this specific scene represents. For example, an        application may use the concept of “goal post” and the user is        thus indicating what location or object should be treated as        “goal post” in this specific scene.    -   To refer to a previously created label. Here the instance of the        application running on the controlling computer already knows        the mapping of label to coordinate or object. In this case the        user is inputting a choice regarding the object. For example,        there could be a number of objects and the user wants the robot        to pick up the selected object now.        We have thus described a system that uses controllable cameras        to calibrate itself and build an internal representation of a        scene, that can guide a robot in real-time within the scene and        that can provide a 3D graphical interface that can interact with        the user both by providing visual information about the scene to        the user and by accepting input from the user regarding        components of the scene.

Application Development

We now describe a programming environment which is designed to allowprogrammers to create applications for the system described in thisdocument. An application created using the programming environment issoftware that is written once but runs on many instances of the system.At any one time, a specific application is running on an instance of thesystem. When we refer to the programming or development of anapplication we mean the application as a class. When we refer to the useor operation of an application we mean a specific instance of theapplication. The purpose of an application is to specify the behavior ofa robot as a function of:

1. The current state within a Finite State Machine (FSM)

2. The configuration of a specific scene

3. The choices of the user regarding the currently desired activity.

4. The location and orientation of the robot and its accessories.

The behavior of a robot refers to the specific action its motors andservos perform. This may be specified in direct terms of motor or servobehavior. For example, the application may specify a current locationtarget, it receives input regarding the current location and orientationof the robot and together with an immediate history of previouslocations it will provide directions to the motors in terms of power,voltage and timing.The system as described frees the programmer from any vision analysis,triangulation or such like. The program can be written simply in termsof the world coordinates as described in the document till now. This cantake two forms. It can be specified in absolute coordinates or incoordinates relative to a specific object within the scene. Thus anapplication can receive coordinate for a robot and take actionaccordingly. This puts programming of the application within the area ofexpertise of a large pool of programmers as opposed to the very specificspecialization of say, stereo scene geometry. The application is writtenin terms of objects referred to by labels. Thus in the example givenbefore, a programmer may write an application in terms of “goal posts”.The application may choose not to specify what or where the “goal post”object actually is. There are two choices of implementation. In one, thesystem can provide the application with the geometry and coordinates ofall objects of the scene together with the image of them and theapplication will apply object recognition techniques and context tospecify that a given object is a goal post. Alternatively, theapplication may ask the user to make a selection using theselection-interaction system described in section 5.7 in order tospecify to the application which object should be the “goal post”.Either way, the goal post ends up as a specific object with a locationin the application instance and the program can execute instructionsrelative to the object/location.In the hierarchy, system-application-instance, application does not meanall the software. The system itself includes a layer of software and theapplication is a layer of software on top of the system software. In thepreferred implementation, the system layer of software runs on thecontrolling computer and comprises the entirety of the firmware on thecamera system and the robot.We now describe one possible method of interaction between theapplication and system software.The system software runs the user interface application. It thereforecontrols the screen resources. The system as seen by a user on thecontrolling computer is a 3D graphic environment. The standard method ofwriting applications where the application controls menu items, buttonsetc. is not applicable in this case. The application software may run asa separate executable, a dynamic link library (DLL) or as a scriptcompiled or interpreted by the system software. If it is a separateexecutable it must establish communication mechanisms with the systemsoftware. If it is a DLL, it provides call-back functions for the systemto call. In any of these three cases, it will not control any screenresources directly. Nevertheless the application designer requires theuser to interact with the system in a way specific to the application.The method proposed for doing this is that the application providesartificial objects for inclusion in the 3D graphic environment. Forexample, the application may provide the triangle mesh and texture for ared 3D cube that when pressed ultimately calls an application function.The application function may change the color of the cube to green toprovide feedback to the user of the interaction and simultaneouslylaunch a routine to, say, move the robot to the first base. The systemsoftware renders the cube in the scene as if it was part of the room.These artificial objects will be referred to as interaction objects.The application can chose to place the interaction objects in the scenein one of two ways:

-   -   The interaction object may be placed in the scene in terms of        coordinates relative to the user's virtual view camera. Thus the        object might always appear on the lower right side of the        screen. The camera referred to here is not the real physical        camera but just the view camera as generated by the 3D graphics        display engine. As the user pans around the scene, the objects        of the scene will obviously be seen to move across the screen.        However, the interaction object will stay in the same place on        the screen (unless the application chooses to move it).    -   The interaction object may be placed in the scene in terms of        absolute world coordinates or relative to labeled objects. For        example, an interaction object may be placed on the floor (y=0        plane) of the scene, next to the object with the “goal post”        label. In that case, the user sees a 3D representation of the        room he/she is sitting on the screen. However, somewhere on the        floor as seen on the user's screen, there is also an object that        is not present in the real room on the floor.        The application is provided notification whenever the user's        mouse moves over the interaction object and whenever the user        clicks on the object. The application can at any time provide        new information to the system software regarding the 3D shape,        texture, color, position or orientation of the object and the        system software will immediately update the user's screen        accordingly. Normally, such changes occur as a result of        information the application receives regarding the user's mouse        activity. However, such changes could also occur as result of        developments in the state of the application or simply as a        function of time.

The application is informed regarding any change in the scene that thesystem is aware of. This would definitely include changes in the robotposition. It may also include other real-time movement of objects in thescene. The system uses motion estimation on the background of a staticimage to recognize when a small area of the image has changed. In thatcase triangulation information for a small area may be achieved atspeeds that are good enough for real time. The application is informedof such changes. The most significant change of this type is when anobject that has a label attached is moved. In such cases the applicationwould require the system to recognize that the object in the newposition is the same as the one in the old position.

It is further noted that any of the embodiments described above mayfurther include receiving, sending or storing instructions and/or datathat implement the operations described above in conjunction with thefigures upon a computer readable medium. Generally speaking, a computerreadable medium may include storage media or memory media such asmagnetic or flash or optical media, e.g. disk or CD-ROM, volatile ornon-volatile media such as RAM, ROM, etc. as well as transmission mediaor signals such as electrical, electromagnetic or digital signalsconveyed via a communication medium such as network and/or wirelesslinks.

Having thus described the foregoing exemplary embodiments it will beapparent to those skilled in the art that various equivalents,alterations, modifications, and improvements thereof are possiblewithout departing from the scope and spirit of the claims as hereafterrecited. In particular, different embodiments may include combinationsof features other than those described herein. Accordingly, the claimsare not limited to the foregoing discussion.

1. A gaming system for providing a gaming service to a user, the gaming system comprising: a. electronic control circuitry; b. a user-directly-controlled self-propelled motorized vehicle (SPMV) operative to move responsively to wirelessly-received user-generated direct commands provided by mechanical motion and/or brainwaves of the user; c. an array of one or more cameras configured to generate an electronic image a scene including the user-directly-controlled SPMV; and d. a computer-directly-controlled SPMV operative to move responsively to computer-generated direct commands that generated by the electronic control circuitry in accordance with: i) one or more game objectives; and ii) a position or orientation, within the electronic image of the scene, of the user-directly-controlled SPMV.
 2. The system of claim 1, wherein the electronic control circuitry generates commands to control translational or rotational movement of computer-directly-controlled SPMV in accordance with at least one of: i) a distance between computer-directly-controlled SPMV and/or user-directly-controlled SPMV and a foreign object as determined in accordance with a Euclidian scene reconstruction of the electronic scene image; ii) historical and/or present and/or predicted future contents of a Euclidian world description data structure as determined in accordance with a Euclidian scene reconstruction of the electronic scene image; iii) historical and/or present and/or predicted contents of a game world description data structure.
 3. The system of claim 1, wherein the electronic control circuitry includes game strategy circuitry for enforcing one or more of the one or more of the game objectives.
 4. The system of claim 1, wherein the electronic control circuitry is operative to: i) detect the user-generated direct commands according to mechanical motion of a user control device or according to a detected gesture of the or a portion thereof; ii) wirelessly transmit the detected commands to the user-directly-controlled SPMV.
 5. The system of claim 1, wherein the user control device is selected from the group consisting of a joystick, a mouse, a keyboard, and an accelerometer.
 6. The system of claim 1, wherein the electronic control circuitry is operative generate the computer-generated direct commands for controlling the computer-directly-controlled SPMV in accordance with game rules of and/or strategy directives for a game selected from the group consisting of: a) a shooting game; b) a ball game; and c) a hand-to-hand combat game.
 7. The system of claim 1, wherein the gaming objective is selected from the group consisting of: a) an objective to score or a goal with a ball or puck; b) an objective to block a goal from being scored with a ball or puck; c) an objective to score or prevent a touchdown or field goal; d) an objective to score a hit against combat game vehicle with a projectile or a beam of light; e) an objective to reduce a probability of a hit being scored against a combat game vehicle with a projectile or a beam of light; and f) an objective to move or grab a game prop with computer SPMV is the game prop is grabbed by user SPMV.
 8. A method of operating an electronic device mounted with onboard lights (EDMOL) such as, but not limited to, a self-propelled motorized vehicle (SPMV), such device including one or more onboard lights operative to sequentially effect a plurality of illumination transitions, each transition modifying brightness and/or color of one or more of the onboard lights, the method comprising: a) electronically controlling the onboard light(s) of the EDMOL to induce an illumination transition that modifies brightness and/or color of one or more of the onboard lights; b) comparing first and second electronic images acquired by the camera, the first image being a pre-transition electronic image describing the EDMOL before the illumination transition and the second electronic image being a post transition electronic image describing the SPMV after the illumination transition; and c) in accordance with results of the comparing and in accordance with the camera calibration data defining the map between the pixel-image locations and the real-world locations, providing real-world Euclidean location information to electronic circuitry operating the EDMOL.
 9. The method of claim 8 where the method further comprises computing, according to a first illumination transition set of one or more illumination transitions as described by the image time series, the camera calibration data itself including extrinsic camera calibration data for the observing camera, the camera calibration data relating pixel-image locations to Euclidian locations.
 10. The method of claim 9 where the EDMOL controlled is a self-propelled motorized vehicle (SPMV) including one or more onboard lights operative to sequentially effect a plurality of illumination transitions, each transition modifying brightness and/or color of one or more of the onboard lights, the method further a) calculating: i) SPMV motor calibration data relating SPMV motor energy inputs to Euclidian displacements describing movement of the SPMV or a portion thereof; ii) servo motor calibration data for a servo on which the observing camera is mounted, the servo calibration data relating servo motor energy inputs to perceived Euclidian displacements of the SPMV as perceived by the servo-moved camera moved the servo; b) determining, according to: i) a second illumination transition set of one or more illumination transitions as described by the image time series; and ii) camera and/or SPMV motor and/or servo motor calibration data, a Euclidian location of the SPMV; and c) controlling rotational and/or translational movement of the SPMV or a portion thereof according to the determined Euclidian location.
 11. The method of claim 10 wherein the method further comprises: a) sending one or more commands to the SPMV or to a servo on which the camera is mounted to induce translational or rotational movement of the SPMV or a portion thereof relative to the observing camera b) obtaining a time series of images of a scene including the SPMV, each image being generated by the observing camera and associated with a different location in appearance space (R, .PHI., I) for the SPMV that is provided according to the commands of step (a); c) computing, according to differences in the appearance of the SPMV in at least some of the images of the time series, calibration data including at least one of: i) camera calibration data including extrinsic camera calibration data for the observing camera, the camera calibration data relating pixel-image locations to Euclidian locations; ii) SPMV motor calibration data relating SPMV motor energy inputs to Euclidian displacements describing movement of the SPMV or a portion thereof; iii) servo motor calibration data for a servo on which the observing camera is mounted, the servo calibration data relating servo motor energy inputs to perceived Euclidian displacements of the SPMV as perceived by the servo-moved camera moved the servo; d) receiving from the client device or the client application a Euclidian command(s) for the SPMV; e) translating the Euclidian movement command(s) to one or more motor command(s) according to the calibration data; f) sending the motor commands of step (e) to the SPMV; g) performing a Euclidian scene reconstruction of one or more images of the time series according to the calibration data; and h) providing a description of the Euclidian scene reconstruction to the client device or client application. It is now disclosed for the first time a method of providing access for a client device or client application to a self-propelled motorized vehicle (SPMV) including one or more onboard lights operative to sequentially effect a plurality of illumination transitions, each transition modifying brightness and/or color of one or more of the onboard lights, the method comprising: a) obtaining a time series of images of a scene including the SPMV, each image being generated by an observing camera observing the scene; b) computing, according to a illumination transition set of one or more illumination transitions as described by the image time series, calibration data including at least one of: i) camera calibration data including extrinsic camera calibration data for the observing camera, the camera calibration data relating pixel-image locations to Euclidian locations; ii) SPMV motor calibration data relating SPMV motor energy inputs to Euclidian displacements describing movement of the SPMV or a portion thereof; iii) servo motor calibration data for a servo on which the observing camera is mounted, the servo calibration data relating servo motor energy inputs to perceived Euclidian displacements of the SPMV as perceived by the servo-moved camera moved the servo; c) receiving from the client device or the client application a Euclidian command(s) for the SPMV; d) translating the Euclidian movement command(s) to one or more motor command(s) according to the calibration data; e) sending the motor commands of step (d) to the SPMV; f) performing a Euclidian scene reconstruction of one or more images of the time series according to the calibration data; and g) providing a description of the Euclidian scene reconstruction to the client device or client application.
 12. The method of claim 8 wherein, i) the camera is mounted on a servo assembly and which subjects the camera to the mechanical rotation according to a delivered power parameter describing delivered power which is delivered to one or more motors of the servo assembly; ii) the candidate rotation angles are selected according to a relationship between the power parameter and an estimated rotation provided by the servo assembly.
 13. The method of claim 8, wherein the method further comprises: f) controlling translational and/or rotational motion of an SPMV in a field of view of the camera in accordance with the computed post-rotation camera external calibration data.
 14. The method of claim 8 wherein a) the onboard light(s) represent a plurality of lights and b) the relative real-world locations of the lights is known and c) the information regarding the relative real-world locations of the lights is utilized by the method to provide real-world Euclidean location information to electronic circuitry operating the EDMOL.
 15. The method of claim 9 wherein a) the onboard light(s) represent a plurality of lights and b) the relative real-world locations of the lights is known and c) the information regarding the relative real-world locations of the lights is utilized by the method to provide real-world Euclidean location information to electronic circuitry operating the EDMOL.
 16. The method of claim 10 wherein a) the onboard light(s) represent a plurality of lights and b) the relative real-world locations of the lights is known and c) the information regarding the relative real-world locations of the lights is utilized by the method to provide real-world Euclidean location information to electronic circuitry operating the SPMV.
 17. A method of operating a self-propelled motorized vehicle (SPMV) 120 including one or more electronically controlled onboard mechanical shutters 124 that effect mechanical shutter transition(s) that modifies color appearance of a location on SPMV housing, the SPMV located within a scene observed by an observing electronic camera 110, the method comprising: a) obtaining first and second electronic images acquired by the camera, the first image being a pre-transition electronic image IMG.sub.PRE describing the SPMV 120 before the mechanical shutter transition and the second electronic image being a post-transition electronic image IMG.sub.POST describing the SPMV 120 after the mechanical shutter transition; and b) comparing the first and second electronic images to determine for each onboard mechanical shutter assembly of one or more of the onboard mechanical shutter assemblies, a respective pixel location within the first and/or second image c) determining, from the pixel location(s) and camera calibration data for the camera, a respective Euclidian location for each onboard mechanical shutter of the one or more onboard mechanical shutter(s); and d) in accordance with the determined Euclidian location(s) of the on-board mechanical shutter(s), electronically controlling rotational and/or translational movement of the SPMV or a portion thereof. 